원클릭으로
using-git-worktrees
Use when developing multiple features in parallel. Isolated workspaces prevent conflicts and enable concurrent branches.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Use when developing multiple features in parallel. Isolated workspaces prevent conflicts and enable concurrent branches.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Coordinate specialized teammates in Agent Teams for execution, review, and planning. Delegate mode mandatory with TaskCompleted/TeammateIdle hooks.
Plan completion workflow - archive plan, verify todos, create git commit, push with retry. Use for finalizing completed plans.
Plan confirmation workflow - extract plan from conversation, create file, auto-review with Interactive Recovery. Use for confirming plans after /00_plan.
Plan execution workflow - parallel SC implementation, worktree mode, verification patterns, GPT delegation. Use for executing plans with TDD + Ralph Loop.
Use when blocked, stuck, or needing fresh perspective. Consults GPT experts via Codex CLI with graceful fallback.
Coordinate independent teammates concurrently in Agent Teams for 50-70% speedup. Launch multiple teammates simultaneously.
| name | using-git-worktrees |
| description | Use when developing multiple features in parallel. Isolated workspaces prevent conflicts and enable concurrent branches. |
Purpose: Parallel development using isolated workspaces for concurrent feature branches Target: Developers working on multiple features simultaneously
# Create new worktree
git worktree add ../project-feature-1 feature-1
git worktree add ../project-feature-2 feature-2
# List worktrees
git worktree list
# Remove worktree after merge
git worktree remove ../project-feature-1
Basic Syntax:
git worktree add <path> <branch> [<start-point>]
Examples:
# Create worktree for existing branch
git worktree add ../myproject-feature feature-x
# Create worktree for new branch
git worktree add ../myproject-experiment -b experiment-branch
# Create worktree at specific commit
git worktree add ../myproject-v1.0 -b v1.0-fixes a1b2c3d
List worktrees:
git worktree list
# Output:
# /path/to/main abc1234 [main]
# /path/to/feature-1 def5678 [feature-1]
# /path/to/hotfix ghi9012 [hotfix/security-fix]
Remove worktree:
# Prune after deleting directory manually
rm -rf ../myproject-feature
git worktree prune
# Remove directly
git worktree remove ../myproject-feature
Lock worktree (prevent cleanup):
git worktree lock ../myproject-critical
git worktree unlock ../myproject-critical
Parallel Development Pattern:
# Main workspace: feature work
cd ~/project-main
git checkout -b feature-auth
# Worktree 1: Hotfix
git worktree add ../project-hotfix -b hotfix-login
cd ../project-hotfix
# Fix hotfix, test, commit, push
# Worktree 2: Experiment
git worktree add ../project-experiment -b experiment-ui
cd ../project-experiment
# Try new UI approach, discard if fails
# Return to main workspace
cd ~/project-main
# Continue feature work, merge hotfix when ready
# 1. Merge feature branch to main
git checkout main
git merge feature-1
# 2. Remove worktree
git worktree remove ../project-feature-1
# 3. Delete branch (optional)
git branch -d feature-1
# 4. Prune stale worktrees
git worktree prune
# Remove all worktrees for merged branches
git worktree list | while read path commit branch; do
if git merge-base --is-ancestor "${branch:0:-1}" main 2>/dev/null; then
git worktree remove "$path"
fi
done
# Create test worktree
git worktree add /tmp/test-worktree -b test-worktree-branch
# Verify it exists
git worktree list | grep test-worktree-branch
# Verify isolation
cd /tmp/test-worktree
git status # Should show test-worktree-branch, not main
# Cleanup
git worktree remove /tmp/test-worktree
Error: working tree '.claude' already exists
Solution: Remove existing worktree first
git worktree list # Find the worktree
git worktree remove <path> # Remove it
Issue: Worktree showing commit hash instead of branch
Fix: Create local branch
cd ../project-worktree
git checkout -b local-branch-name
Version: claude-pilot 4.3.0