SuperAPI AI Directory

agent-worktrees

Agents & models

View repository

Updated 10-16 07:15

About this skill

Agent worktrees

Chat: RESPONSE.md. Full method: METHODOLOGY.md.

Operating order

1. Should we isolate? (§1)

≥2 agents on this repo → yes. User/product says share → obey. Overlapping structural files → serialize even with worktrees.

2. Already isolated?

If you're already in a worktree (common dir ≠ toplevel of a single checkout) and a branch exists for this task → skip create; run setup if share links missing.

3. Create branch + worktree (§2.1)

Off main. Prefer Linear branch name when tracked. Don't double-create Claude Code's claude/<name> trees.

4. Share env (§2.2)

bash scripts/worktree.sh setup

Symlink, never copy. Configure share list for this stack (see METHODOLOGY §2.2 table).

5. Preview + claim + status (§2.3–2.5)

Own auto-ported server. Declare <branch> · <task>. End every message with:

🔌 <branch> · <one-line task> · <preview URL>

6. Land + teardown (§2.6–2.7)

bash scripts/worktree.sh land <branch>
git push origin main
bash scripts/worktree.sh teardown ../<repo>-<slug> <branch>

Clear the claim. Stop the preview before teardown.

7. Done check (§6)

Rubric ≥10/12, no zeros.

Install into a repo

See METHODOLOGY §4. Prefer existing repo scripts/worktree.sh; else copy from this pack. Optional worktree.share. Write the six-step protocol into agent instructions; smoke-test once.

Out of scope

Single-agent main-tree work. Schema-migration strategy beyond "serialize on shared DB." Idle-time autopull (sibling concern).