worktree
Worktree
Drive the lifecycle of an isolated git worktree: detect existing isolation,
create a fork through doctrine worktree fork (the verb that adds the
worktree, provisions it, and optionally stamps the worker marker — all with
compensating rollback; the fork builds into its own in-tree target/), run the
spawn guards, and verify a green baseline before handing off.
Announce at start: "Using the worktree skill to set up an isolated workspace."
This is a sub-skill. /execute (mode=solo) invokes it for opt-in isolation;
/dispatch-subprocess invokes it for codex/pi workers; the /dispatch router
invokes the coordination path (worktree coordinate, below) for the
per-run dispatch/<slice> tree. (The claude worker arm, /dispatch-agent, does
not use fork — Claude default-creates the worktree and a SubagentStart hook
stamps it; see that skill.) It is not a /route destination — reach it through the
caller.