tsk-q4211v7mxk5p Proposed
Oliver 2026-11-10 (chat 104129, 104167): worktrees on a runner stay off by default. The owner can turn them on as an option.
Constraints from that conversation:
- Coder and reviewer must stay separable. A worktree belongs to exactly one agent's own clone and never spans two agents or two placements. Different agents keep separate clones and credentials, as today.
- Off by default; on only by the owner's explicit choice. Where the switch lives (agent profile, placement, or runner config) is part of the design.
Design first (to Oliver before any code):
- Which pointer files are allowed (
.git/worktrees/<name>/gitdir,commondir,config.worktree,extensions.worktreeConfig), and how clonecheck proves they point only inside the same clone. - Where worktrees live so the Claude sandbox lets the agent write them (inside the clone).
- What the runner does with them on cleanup, handover and replacement (§15.14), and in
maity report. - What happens to the sandbox's empty placeholder files (see tsk-2zz5tjpbt28n).
Starts after #1595 (tsk-2zz5tjpbt28n) and the git docs (tsk-090wm1dqx6y3).