worktree-isolation
Skill0 starsChanged 56 days agoMITView on GitHub
Isolates work in a sibling git worktree, then merges and cleans up. Use to keep a change out of the main checkout or when parallel tracks collide.
5 other projects use a version of this.
Adopted by
Most recently taken up by
- aditya-deokar/software-factorytheir own version, first seen Sep 29, 2026
- orkait/hyperstacktheir own version, first seen Jun 14, 2026
- sunduq-ai/falqtheir own version, first seen Jun 12, 2026
- nicolai-bernsen/backlogdtheir own version, first seen Jun 7, 2026
- alex-voloshin-dev/ai-skillstheir own version, first seen May 17, 2026
Other versions5 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 5
- sunduq-ai/falq★ 4same name
- alex-voloshin-dev/ai-skills★ 2same name
- nicolai-bernsen/backlogd★ 2same name
- aditya-deokar/software-factory★ 1same name
- orkait/hyperstack★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository52 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .claude/CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- best-practices-auditSkill
- catalog-authoringSkill
- cli-toolsSkill
- conventional-commitsSkill
- decompose-planSkill
- falsify-firstSkill
- find-skillsSkill
- harness-clientSkill
- harness-loopSkill
- interface-factsSkill
- no-commentsSkill
- nodeSkill
- plain-englishSkill
- pythonSkill
- release-processSkill
- repair-in-placeSkill
- retention-probeSkill
- root-causeSkill
- session-finishSkill
- skill-creatorSkill
- test-disciplineSkill
- tier-injectionSkill
- validate-as-consumerSkill
- work-trackerSkill
- worktree-isolationSkill
- best-practices-auditSkill
- catalog-authoringSkill
- cli-toolsSkill
- conventional-commitsSkill
- decompose-planSkill
- falsify-firstSkill
- find-skillsSkill
- harness-clientSkill
- harness-loopSkill
- interface-factsSkill
- no-commentsSkill
- nodeSkill
- plain-englishSkill
- pythonSkill
- release-processSkill
- repair-in-placeSkill
- retention-probeSkill
- root-causeSkill
- session-finishSkill
- skill-creatorSkill
- test-disciplineSkill
- tier-injectionSkill
- validate-as-consumerSkill
- work-trackerSkill
The file
We split this skill into the rules it gives an agent
2 rules. 0 are common, 1 is distinctive, and 1 is very specific to this project.
0
Common
Most of the 5 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 38
Work: Do the change in the worktree.
- Very specific: line 40
Use merge or merge-queue only for a worktree that the loop does not drive.
“Common” is measured: kept by at least 6 in 10 of the 5 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
<!-- Generated by `basicly skills-build` from skill.yaml. Do not edit; edit the source. -->Worktree Isolation
This skill runs a unit of work in a sibling git worktree with basicly worktree.
It covers placement, provisioning, merge and cleanup.
For tracker records see work-tracker. For commits see the git reference of cli-tools and conventional-commits.
Rules
- Isolate every non-trivial change. This includes multi-file work, work that runs the gates, and work parallel to another track.
- Skip isolation for a trivial edit, such as a typo. A worktree has a real setup cost.
- Put the worktree at the sibling path
<repo>.worktrees/<name>. A worktree inside the repository is not provisioned, so its hooks run no gates. - Never pass
-c core.hooksPath=...in a worktree. A relative path skips every hook with no message. - Do not resolve a merge conflict by hand. A conflict means the scopes missed a coupling, so the lane applies its intent again on the new base.
- Run merge commands from the base checkout. Git refuses to update a branch that another worktree has checked out.
Lifecycle
basicly worktree create <name> [--base <branch>] # add and provision
basicly worktree list # active sessions; stale ones are marked
basicly worktree merge <name> --bead <id> [--mode M] # rebase, verify, --no-ff merge
basicly worktree merge-queue <name>:<id> ... [--mode M] # merge several, in the given topological order
basicly worktree cleanup <name> [--force] # remove the worktree and its merged branch- Create. The worktree gets the branch
harness/<name>, from[worktree].base_branchinbasicly.tomlor the current branch. It gets its own.venv(uv sync) and its ownnode_modules. Thenode_modulestree is copied from a checkout with an identicalpackage-lock.json, else it comes fromnpm install. Neither tree is a symlink to the main checkout, so cleanup is safe. The command installs the repository's git hooks for every stage. It refuses when[worktree].concurrencyis reached. Read the configured value. - Work. Do the change in the worktree. Its hooks gate each commit as on the main checkout.
- Merge. Under
basicly loop, the build-to-verify advance merges for you. Usemergeormerge-queueonly for a worktree that the loop does not drive. - Clean up.
cleanupremoves the worktree, prunes the registry, and deletesharness/<name>when it is merged. It keeps an unmerged branch unless you pass--force. It never touches the base branch. It can reclaim a worktree whose directory is gone.
Hooks
A linked worktree's .git is a file. Git resolves its hooks to the shared common directory.
Provisioning installs the hooks there, so a plain git commit in the worktree runs every gate.
A relative override such as git -c core.hooksPath=.git/hooks commit resolves inside the worktree.
There .git/hooks does not exist, so git skips pre-commit, commit-msg and the record id check.
The commit looks clean, and the defect shows only on a later commit.
To see where hooks resolve, read the path:
git rev-parse --git-path hooksClaude Code
The Claude Code setting worktree.bgIsolation (on by default) moves a background agent into .claude/worktrees/.
That conflicts with sibling worktrees. Run this once per repository to set it to none:
basicly worktree bg-isolationThe command writes the committed .claude/settings.json, so it asks for consent. --yes gives that consent.
Codex and Copilot have no equivalent setting.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

