06 · Simple branching

Branching is a powerful concept from source control systems. The latest Patchwork experiment explores whether writers could benefit from branches:

A “branch” is a variation of a document that can be edited independently. This allows a writer to experiment without worrying about messing up the main version. And it allows multiple writers to try things in parallel without bothering each other. Eventually, any given branch can be merged back to the main doc—or discarded if it turned out to be a direction that didn’t work out.

Our previous Edit Groups prototype explored tools for editing on a single shared version of a document without branching. The simple branches experiment leans entirely in the other direction. We think that “branch” is a great name and a great concept, and if we can provide a simple, comprehensible UI and avoid footguns we belive it’s something writers can learn and benefit from.

A key attribute of this prototype is that it’s fast and low-ceremony to create branches, switch between branches, and merge or delete branches.

A branch picker, similar to GitHub or Upwelling, sits in the upper left.

Users still edit on main by default, so you can send a doc to someone and they can make changes without understanding branches. You can also create a branch retroactively with your current edit session, including a mouse-over diff that shows what changes will go into the branch (and be removed from main) if you pick this.

Hovering over the retroactive branch option highlights the diff of changes to move.

To keep things simple:

We’ve been using simple branches to suggest edits on posts to the lab notebook, including this one. So far, we’re finding the prototype compelling for individual use (e.g. trying experimental directions) and for collaboration (sending a link to the branch, including edits and comments, to a coauthor). One direction we’d like to explore further is using a stronger spatial metaphor to give users a sense of how branches and the main document relate to each other.

Next entry: 07 · AI bots in version control

Sign up to the Ink & Switch Dispatch

Occasional stories from Ink & Switch about our work, publications, talks, and the people at the lab. Browse the archive.