agentleFS
aprameyakaprameyak/coding-skills/git-worktree/SKILL.md

git-worktree

Skill1 starsChanged 58 days agoMITView on GitHub

Use git worktrees for isolated parallel work. Use when running parallel agents, long-lived features beside hotfixes, or when the user asks for a worktree.

27 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use grill-with-docs, caveman and 3 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • MicrosoftSkill

    grill-with-docs

    Grilling session that challenges your plan against the existing domain model, sharpens terminology, and updates documentation (CONTEXT.md, ADRs) inline as decisions crystallise. Use when user wants to stress-test a plan against their project's language and documented decisions.

    Also in 4 projects that use this

  • MicrosoftSkill

    caveman

    Ultra-compressed response style that reduces output token count while preserving technical accuracy, with intensity levels and auto-clarity safety rules

    Also in 3 projects that use this

  • Google CloudSkill

    triage

    Gather context on a change or bug and plan the implementation.

    Also in 3 projects that use this

  • AWSSkill

    grill-me

    A relentless interview to sharpen a plan or design.

    Also in 4 projects that use this

  • OpenAISkill

    brainstorming

    You MUST use this before any creative work - creating features, building components, adding functionality, or modifying behavior. Explores user intent, requirements and design before implementation.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

8 rules. 0 are common, 7 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 22 edited versions we read keep these.

  • 7

    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
  1. Distinctive:

    Create a worktree in a sibling directory with a dedicated branch.

    line 11
  2. Distinctive:

    Do all work for that task inside the worktree cwd.

    line 12
  3. Distinctive:

    Run tests/commits in that worktree only.

    line 13
  4. Distinctive:

    Remove the worktree when the branch is merged or abandoned.

    line 14
  5. Distinctive:

    Do not reuse one dirty working tree for conflicting tasks.

    line 27
  6. Very specific:

    Keep worktree paths predictable and outside nested .git confusion.

    line 28
  7. Distinctive:

    Never delete a worktree with uncommitted needed work without checking status.

    line 29
  8. Distinctive:

    Prefer worktrees over stashing tennis for long parallel efforts.

    line 30

“Common” is measured: kept by at least 6 in 10 of the 22 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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Git Worktree

Process

  1. Confirm a clean understanding of branch name and purpose.
  2. Create a worktree in a sibling directory with a dedicated branch.
  3. Do all work for that task inside the worktree cwd.
  4. Run tests/commits in that worktree only.
  5. Remove the worktree when the branch is merged or abandoned.

Commands

git fetch origin
git worktree add ../repo-feature -b feature/name origin/main
git worktree list
git worktree remove ../repo-feature

Rules

  • Do not reuse one dirty working tree for conflicting tasks.
  • Keep worktree paths predictable and outside nested .git confusion.
  • Never delete a worktree with uncommitted needed work without checking status.
  • Prefer worktrees over stashing tennis for long parallel efforts.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.