# Spontaneous (non-)branching vs. tree-style branches

**URL:** <https://discourse.pijul.org/t/spontaneous-non-branching-vs-tree-style-branches/47>\
**Category:** Development\
**Created:** [June 15, 2017, 11:14pm UTC](https://discourse.pijul.org/t/spontaneous-non-branching-vs-tree-style-branches/47 "2017-06-15T23:14:39Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![pointfree](https://yyz1.discourse-cdn.com/flex031/user_avatar/discourse.pijul.org/pointfree/32/13_2.png) [@pointfree](https://discourse.pijul.org/u/pointfree)\
**Post date:** [August 1, 2017, 6:11pm UTC](https://discourse.pijul.org/t/spontaneous-non-branching-vs-tree-style-branches/47/6 "2017-08-01T18:11:13Z")

</div>

I agree, it would be best to keep this on the ui-side.

It occurred to me that the existing tree-style pijul branches ui could be enhanced to support the spontaneous workflow while still supporting different stances on which patches belong to a branch.

`pijul fork` with a filter could fork to a new branch containing only: repo origin + patches matching the filter + those patches’ dependencies. In other words, a partial fork.

Of course, users would usually want to work out of a full fork.

`pijul record` could accept a branch or branches as an argument so that one would not need to work directly inside a partial fork. Upon recording to another branch than the working copy, dependencies would have to be applied to the other branch as well.

> [@flobec](#):
>
> how these metadata get propagated or not.

`pijul fork` would effectively create that metadata, in other words, it would create a branch. The branch name would be the metadata. `Push`ing, `pull`ing, and `unrecord`ing between branches effectively shuffles that metadata around.

With at least some ui enhancements to `pijul checkout`, merging branches could support the spontaneity of picking multiple filters if `pijul checkout` could accept more than one branch as an argument.

Just a brainstorm for now.

---

_[View the full topic](https://discourse.pijul.org/t/spontaneous-non-branching-vs-tree-style-branches/47)._
