worktree-setuplisted
Install: claude install-skill punkaze/skills
# Worktree Setup
Set up isolated git worktree(s) for a task, deciding **single vs dual/multi repo scope** from the nature of the change, using a per-project **config**. **Setup only** — creates worktree(s) + branch(es), copies env, installs deps, registers the primary worktree, then hands back. It does NOT plan or implement.
> **REQUIRED BACKGROUND:** Read the underlying git-worktree isolation logic for your toolchain. This skill layers per-project config (base branch, install, env-copy, coupling) on top.
> **Paths:** scripts live at `${CLAUDE_PLUGIN_ROOT}/skills/worktree-setup/scripts/`. Persistent per-project configs live at `${CLAUDE_PLUGIN_DATA}/projects/` (survives plugin updates), overridable with `WORKTREE_REGISTRY_DIR`. A bundled `projects/example.json` documents the format.
## When to trigger
- "set up a worktree for <X>" · "start a worktree for this task" · `/skills:worktree-setup <task>`
- "isolate this work in a worktree" (inside a configured repo)
- Before a `subagent-driven-development` / `executing-plans` run on a repo not already in a linked worktree
## When NOT to trigger
- **No config matches** the current repo and the user did not ask to set one up → no-op (offer `init`).
- **Already in a linked worktree** (`GIT_DIR != GIT_COMMON`) → work in the one you're in.
- **Trivial one-file fix** the user wants in place (`git switch -c fix/<slug>`) → no worktree.
## Step 0 — Resolve config (always first)
```bash
node "${CLAUDE_PLUGIN_ROOT}/skills/worktree-se