Branches and safe preview worktrees
Preview branches let a user test source/data mutations in isolated worktrees while preserving the same URL shape, graph identity, and Inspector surfaces. The switchboard is a system capability (hypermake branches list works here); this corpus does not yet stage a live preview toggle — the diagram below describes the promoted routing model.
Same URL, selected backend
The browser sees one dev origin; Hypermake routes the session to the chosen worktree backend.
Preview lifecycle
| Step | State | User choice |
|---|---|---|
| Create | New worktree backend and graph roots. | Open preview or keep main. |
| Edit | Mutations apply to preview source/data only. | Commit more changes or discard. |
| Validate | Testing digest and diagnostics run against preview graph. | Promote if green. |
| Promote | Changes move back to main through normal git/graph flow. | Review and commit. |