Back to Settings

Worktree Context Statusline

Settings statusline 19 NVIDIA SkillSpector Scanner

Minimal worktree-aware status line showing project name, git branch, model, and accurate context usage. In a linked git worktree it shows the main project name instead of the worktree folder and marks the branch with ⑂. Context percentage and window size (200k or 1M) come directly from Claude Code's context_window data, so it stays correct for extended-context models. The context segment is hidden until the first API response and right after /compact.

Install Command
npx claude-code-templates@latest --setting statusline/worktree-context-statusline
View on GitHub
claude-code — worktree-context-statusline

Content

JSON
{
"description": "Minimal worktree-aware status line showing project name, git branch, model, and ..."
"statusLine": {
"type": "command"
"command": "python3 .claude/scripts/worktree-context-statusline.py"
}
}

Stack Builder

0 components

Your stack is empty

Browse components and click the + button to add them to your stack for easy installation.