brainstorming
Refine feature and sprint intent into a useful specification. Capture scope, observable criteria and material choices without…
OPTIONAL per-task isolation for autonomous parallel work. Routed to only on explicit opt-in by subagent-driven-development or dispatching-parallel-agents, so parallel units mutate files without colliding. Stands up one worktree per unit, works it in isolation, then integrates
Claude Code
$ npx -y skills add arbiterForge/codeArbiter --skill using-git-worktrees --agent claude-code
Codex
$ npx skills add arbiterForge/codeArbiter --skill using-git-worktrees -a codex -y
Cursor
$ npx skills add arbiterForge/codeArbiter --skill using-git-worktrees -a cursor -y
Gemini CLI
$ npx skills add arbiterForge/codeArbiter --skill using-git-worktrees -a gemini-cli -y
GitHub Copilot
$ npx skills add arbiterForge/codeArbiter --skill using-git-worktrees -a github-copilot -y
OpenCode
$ npx skills add arbiterForge/codeArbiter --skill using-git-worktrees -a opencode -y
Windsurf
$ npx skills add arbiterForge/codeArbiter --skill using-git-worktrees -a windsurf -y
name: using-git-worktrees description: OPTIONAL per-task isolation for autonomous parallel work. Routed to only on explicit opt-in by subagent-driven-development or dispatching-parallel-agents, so parallel units mutate files without colliding. Stands up one worktree per unit, works it in isolation, then integrates each unit back onto the caller's working branch for the caller's single commit-gate + finishing-a-development-branch exit. Never on the default path; it does not bypass a gate or finish per unit. disable-model-invocation: true
OPTIONAL. Per-task filesystem isolation for parallel agent work — opt-in only, never the default path. Routed to by `subagent-driven-development` and `dispatching-parallel-agents` when, and only when, the caller requests isolation. If no isolation is requested, this skill does not run; parallel units share the working tree under their own discipline.
Isolation lets concurrent units edit files without collision. It changes nothing about the gates — the consolidated work still clears `commit-gate` and the single `finishing-a-development-branch` terminal step, run by the caller. What it MUST NOT do is multiply that terminal step into one PR per unit.
Read these, or STOP and surface the gap — never guess:
exact selected plan for the parallel unit list. Re-run the private bridge resolver `_resolve_workflow_pair` with the trusted project root and pipeline slug rather than reconstructing either path. For an HTML pair, load `{{PLUGIN_ROOT}}/includes/artifacts.md` and obtain HTML task and path records only through the installed engine `identity`, `index`, and symbol-scoped `read` operations. For a Markdown pair, use its existing Markdown task table. Worktree planning must not create, convert, or consult a counterpart.
Confirm the caller selected isolation within its current authorized scope AND supplied the parallel unit list from the exact selected plan. Absent either, do not stand up worktrees. A selected isolation method is not new authority to discard a branch or worktree.
Stand up one worktree per parallel unit. For each unit, create a worktree on a fresh branch off the current base, under a dedicated parent directory outside the main working tree (e.g. `../.codearbiter-worktrees/<slug>`):
Before provisioning, inventory dirty inputs relevant to each unit and record each path's SHA-256 or absence. A fresh worktree does not contain uncommitted caller bytes. If a dirty input overlaps a unit-owned path, stop: the unit cannot safely distinguish caller work from its own delta. Otherwise, reproduce it only as a read-only baseline, verify its hash before and after unit work, and exclude it from the unit index and commits. Recheck the caller copy is still byte-identical before fold-back. Preserve unrelated dirty paths by leaving them untouched.
Gate: every unit has a distinct worktree on a distinct branch, all rooted at the same verified base and recorded for resumption. Every relevant dirty input is either a content-addressed read-only baseline outside unit ownership or a named stop; unit commits exclude those baselines, and no cleaning, resetting, stashing or overwriting occurred.
Each parallel unit works entirely inside its own worktree. Dispatch is unchanged — the caller still dispatches its author and reviewer agents; they simply operate on the isolated path.
Gate: each unit's work is contained to its own worktree, with no cross-worktree or base-branch writes.
Integrate each isolated unit's work back onto the caller's single working branch — do NOT finish each unit on its own. Per unit, in order:
1. Confirm the unit was accepted by the caller under its applicable completion and check contract. Inspect accessible command, cwd, source/input identity, output and exit status; reuse valid evidence and rerun only missing or affected checks. An explicit review batch retains its triaged verdict. An unaccepted unit does not fold back. 2. Integrate its branch onto the caller's working branch (merge or rebase), resolving any conflict here, in the open. If a rebase rewrites the unit branch, immediately refresh its recorded tip in the handoff before fold-back and use that refreshed tip for later ancestry proof. Never integrate onto `main` or the default branch.
The consolidated working branch then takes the caller's normal single exit — ONE `commit-gate` pass and ONE `finishing-a-development-branch` decision, run by the caller, not per unit. This skill integrates; it never opens N PRs or finishes N branches. A unit that cannot integrate cleanly is surfaced as a conflict for resolution — never force-merged, never dropped silently.
Gate: every accepted unit integrated onto the caller's working branch with conflicts resolved; no per-unit PR or finish was opened.
Record which worktrees and branches remain after fold-back. Integrated unit worktrees and branches remain retained by default: they have no per-unit merge
Open-source governance and hard gates for AI coding agents across Claude Code, Codex CLI, and Pi.
Refine feature and sprint intent into a useful specification. Capture scope, observable criteria and material choices without…
Create a verified local Git commit when committing changes is requested. Not for explaining commit history, drafting a message…
Inspect context drift and refresh selected source-backed documents under existing authorization.
Build source-backed project context through bounded inspection, optional agents, and record-level knowledge writes.
The banned-primitive gate. Routed to when changed code hashes, signs, encrypts, derives keys, generates security-relevant…
Investigate an unexplained defect or unexpected behavior without changing application code. Use for root-cause diagnosis and an…
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…
Ask which skill or flow fits your situation. A router over the skills in this repo.