This page was translated automatically from English, the only language this site is written in. Read the original.
A branch's worktree path is derived from git identity and the branch name alone — the primary checkout's sibling named with -wt, then the branch with its hierarchy kept — and is the same answer from every directory of every worktree, with nothing registered or configured
Given the repository and a branch name there is exactly one path for that branch's
declared status○declared status: guaranteedDeclared deterministic and blocking, implemented, and naming the behavioural test that is to prove it. Whether a recorded run supports it is the evidence verdict, shown beside it.
recorded evidence○recorded evidence: not runDeclared guaranteed, and not supported by a recorded run: the test is named, and no passing run of the current inputs is recorded. how evidence is recorded
The identity is the common git directory and the main worktree git lists first, never the current directory, so a linked worktree does not derive a container inside itself. The branch name is validated by git's reference rules and the derived path is proved on every call to stay below the container. Every registered worktree gets a standing and every condition a stable code with a remedy; the four worktree.* capabilities project the same typed topology to MCP, HTTP, OpenAPI, the Swagger UI and the Cockpit, and the pre-commit hook asks the guard.
Given the repository and a branch name there is exactly one path for that branch's
worktree — <repo>-wt/<branch>, the primary checkout's sibling named with -wt, then the
branch's components as directories — and every surface computes it the same way from git's
own identity. No file, section, table or list records it, and adding a branch edits nothing.
RepositoryIdentity::discover reads git rev-parse --git-common-dir and git worktree list --porcelain; the first record is the primary checkout, whatever directory the command
ran in. path::container_root appends the suffix to its name; path::expected_path joins
the validated branch name and proves the result stays strictly below the container.
WorktreeService::judge gives every registered worktree a standing — primary, canonical,
misplaced, detached, ephemeral, missing — and every condition a DiagnosticCode with a
remedy. The four worktree.* capabilities project the typed RepositoryTopology; the
command line renders it; worktree guard decides for the pre-commit hook.
A git hook is bypassed with --no-verify, and a CI runner cannot see a contributor's local
directories: the gate holds the rule's machinery together, not this machine's filesystem.
Bare repositories are refused by name.
Fifty-three worktrees in four shapes, eleven of them dirty, and no answer to "where is
branch X" that did not involve looking or inventing. ADR 21 records the decision.
A branch's worktree path is derived from git identity and the branch name alone — the primary checkout's sibling named with -wt, then the branch with its hierarchy kept — and is the same answer from every directory of every worktree, with nothing registered or configured