Claude Code Integration
The worktrunk Claude Code plugin provides three features:
- Configuration skill β Documentation Claude Code can read, so it can help set up LLM commits, hooks, and troubleshoot issues
- Worktree isolation β When Claude Code agents create isolated worktrees, the plugin routes creation and removal through
wtinstead of rawgit - Activity tracking β Status markers in
wt listshowing which worktrees have active Claude sessions (π€ working, π¬ waiting)
Installation
Recommended:
wt config plugins claude install
Manual equivalent:
claude plugin marketplace add max-sixty/worktrunk
claude plugin install worktrunk@worktrunk
Configuration skill
The plugin includes a skill β documentation that Claude Code can read β covering worktrunk's configuration system. After installation, Claude Code can help with:
- Setting up LLM-generated commit messages
- Adding project hooks (pre-start, pre-merge, pre-commit)
- Configuring worktree path templates
- Fixing shell integration issues
Claude Code is designed to load the skill automatically when it detects worktrunk-related questions.
Activity tracking
The plugin tracks Claude sessions with status markers in wt list:
wt list
Branch Status HEADΒ± mainβ Remoteβ
Path Commit Age Message
@ main ^β‘ β‘1 . 33323bc1 1d Initial commit
+ feature-api β π€ β1 ../repo.feature-api 70343f03 1d Add REST API endpoints
+ review-ui ? β π¬ β1 ../repo.review-ui a585d6ed 1d Add dashboard component
+ wip-docs ? β ../repo.wip-docs 33323bc1 1d Initial commit
β Showing 4 worktrees, 2 with changes, 2 ahead
- π€ β Claude is working
- π¬ β Claude is waiting for input
Manual status markers
Set status markers manually for any workflow:
wt config state marker set "π§" # Current branch
wt config state marker set "β
" --branch feature # Specific branch
git config worktrunk.state.feature.marker '{"marker":"π¬","set_at":0}' # Direct
Worktree isolation
Claude Code agents can run in isolated worktrees (isolation: "worktree"). By default, Claude Code creates these with git worktree add. The plugin's WorktreeCreate and WorktreeRemove hooks route this through wt switch --create and wt remove instead, so worktrees created by agents get worktrunk's naming conventions, hooks, and lifecycle management.
Statusline
wt list statusline --format=claude-code outputs a single-line status for the Claude Code statusline. When the CI status cache is stale, this fetches from the network β typically 1β2 seconds β making it suitable for async statuslines but too slow for synchronous shell prompts. If a faster version would be helpful, please open an issue.
~/w/myproject.feature-auth !π€ @+42 -8 β3 β‘1 β | Opus π 65%
When Claude Code provides context window usage via stdin JSON, a moon phase gauge appears (πβπ as context fills).
Add to ~/.claude/settings.json:
{
"statusLine": {
"type": "command",
"command": "wt list statusline --format=claude-code"
}
}