parallel-worktrees
Parallel Worktrees
Productivity pattern for running multiple Claude Code sessions on the same repository.
See ../../rules/12-context-management.md for detailed documentation.
Quick Reference
Setup
# Create worktree for a feature branch
git worktree add ../feature-name feature/branch-name
# Launch Claude in the worktree
cd ../feature-name && claude
Writer/Reviewer Pattern
| Terminal | Role | Command |
|---|---|---|
| Terminal 1 | Writer | cd ../feature-auth && claude "Implement feature" |
| Terminal 2 | Reviewer | cd ../review-auth && claude "Review the code" |
Best Practices
- 3-5 worktrees maximum
- One worktree = one task
- Remove completed worktrees:
git worktree remove ../feature-name - Never share sessions between worktrees
Cleanup
# List all worktrees
git worktree list
# Remove a worktree
git worktree remove ../feature-name
# Prune stale worktree entries
git worktree prune
More from thebeardedbearsas/claude-craft
kiss-dry-yagni
Principes KISS, DRY, YAGNI. Use when reviewing code quality or refactoring.
96documentation
Documentation. Use when writing docs or reviewing documentation.
31solid-principles
SOLID principles for object-oriented design. Use when reviewing code quality, refactoring, designing classes or interfaces, or discussing architecture patterns.
23git-workflow
Git workflow and conventional commits. Use when working with git, branches, commits, pull requests, code review, or version control strategy.
18security-reactnative
Security - React Native Best Practices. Use when reviewing security, implementing auth, or hardening code.
17architecture-clean-ddd
Architecture Clean + DDD + Hexagonal - Atoll Tourisme. Use when designing architecture or reviewing code structure.
16