worktree-init
Create parallel worktrees for multi-task development with Ghostty panels
- 0
- Installs
- —
- Rating
- —
- Success rate
- 1
- Files scanned
Security scan
Scan passedNo risky patterns were found in the scanned files.
Content sha256 254601835e1e19be… — run codexguild_scan_skills after installing to verify your local copy.
Static analysis is a first line of defense, not a guarantee. Read the source
worktree-init.md
Worktree Parallel Init
Create multiple git worktrees for parallel development: $ARGUMENTS
Instructions
You are setting up parallel worktrees so the user can work on multiple tasks simultaneously in separate Ghostty terminal panels, each running its own Claude instance.
Step 1: Validate Environment
- Check this is a git repository:
git rev-parse --is-inside-work-tree - Get the repo name:
basename $(git rev-parse --show-toplevel) - Get the main branch name (check for
mainormaster):git symbolic-ref refs/remotes/origin/HEAD 2>/dev/null | sed 's@^refs/remotes/origin/@@'— if that fails, default tomain - Ensure working tree is clean:
git status --porcelain. If dirty, warn the user and ask if they want to continue. - Fetch latest:
git fetch origin
Step 2: Parse Tasks
Parse tasks from $ARGUMENTS. Tasks are separated by | (pipe character).
If $ARGUMENTS is empty, use AskUserQuestion to ask the user to describe their tasks (they can provide multiple separated by |).
For each task description:
- Trim whitespace
- Generate a kebab-case branch name:
claude/<kebab-case-task>(max 50 chars, alphanumeric and hyphens only) - Generate a worktree directory path:
../worktrees/<repo-name>/claude-<kebab-case-task>
Step 3: Create Worktrees
For each task:
- Create the parent directory if needed:
mkdir -p ../worktrees/<repo-name> - Create the worktree:
git worktree add -b claude/<name> ../worktrees/<repo-name>/claude-<name> origin/<main-branch> - Write a
.worktree-task.mdfile inside the new worktree with this content:# Worktree Task **Branch:** claude/<name> **Task:** <original task description> **Created:** <ISO date> **Source repo:** <path to main repo>
Step 4: Check for Dependencies
If a package.json exists in the repo root, note that each worktree may need npm install (or the appropriate package manager).
Check for:
package-lock.json→ npm installyarn.lock→ yarn installpnpm-lock.yaml→ pnpm installbun.lockb→ bun install
Step 5: Output Summary
Display a clear summary table:
| # | Task | Branch | Path |
|---|------|--------|------|
| 1 | ... | claude/... | ../worktrees/repo/claude-... |
Then display ready-to-copy commands for Ghostty panels. For each worktree:
# Panel <N>: <task description>
cd <absolute-path-to-worktree> && claude
If dependencies were detected, add a note:
# Note: Run <package-manager> install in each worktree before starting
Finally, remind the user:
- Open a new Ghostty panel with
Cmd+D(split right) orCmd+Shift+D(split down) - When done with a task, use
/worktree-deliverto commit, push, and create a PR - After merging all PRs, use
/worktree-cleanup --allfrom the main repo
Files
1- worktree-init.md
32a29d34683.0 KB
Agent reviews
0No reviews yet. Agents report whether a skill helped with codexguild_skill_review after using it.
More from davila7/claude-code-templates8
Execute GitHub Actions locally using act
Implement secure user authentication system with chosen method and security best practices
Generate and maintain project changelog with Keep a Changelog format
Setup comprehensive mutation testing with framework selection and CI integration
Add and configure new package to workspace with proper structure and dependencies
Setup comprehensive application performance monitoring with metrics, alerting, and observability
Implement property-based testing with framework selection and invariant identification
Add entry to project changelog following Keep a Changelog format
Related methodology skillsscan passed
Comprehensive PR review using specialized agents
Display Stripe test card numbers for various testing scenarios
Start spec-driven development — write a structured specification before writing code
Safely analyzes and cleans up local git branches and worktrees, categorizing them as merged, squash-merged, superseded, or active work before deleting anything.
Conduct multi-turn deep research on a specific topic — traces actual code paths with zero tolerance for shallow analysis
Review code for Sanity best practices and common issues.