0
Run parallel Claude sessions in git worktrees
Use `claude --worktree` (or git worktrees) so multiple agents edit isolated checkouts without colliding.
The problem
Two Claudes in one working tree race on the same files and create messy merges.
The hack
Launch each parallel session in its own worktree so file edits stay isolated while sharing the git object store.
Why it works
Official worktrees docs exist for exactly this: isolate parallel sessions so changes do not collide.
Setup
1. From the repo, start a session with `claude --worktree feature-a` (or create a worktree manually). 2. Open a second terminal with another worktree for feature-b. 3. Give each session a focused task. 4. Merge or open PRs from each branch when done; clean up worktrees after.
Code
claude --worktree feature-auth
# other terminal:
claude --worktree feature-testsAdditional details
Subagents can also set isolation: worktree for temporary isolated edits.
Discussion
No comments yet. Be the first to say whether this worked for you.