A small, configurable statusline for Claude Code. Bash + jq, or native PowerShell. Nothing else.
Shows: dir, GitHub account, git branch, AWS profile, model, session cost, context %, 200k flag, 5h rate limit, duration, lines changed. Each toggleable.
Paste this prompt into Claude Code:
Install ccline from https://github.com/itzTiru/ccline
Claude will clone the repo, run the correct installer for your platform, and verify the install.
One-liner:
curl -fsSL https://raw.githubusercontent.com/itzTiru/ccline/main/setup.sh | bashOr clone + install:
git clone https://github.com/itzTiru/ccline.git ~/.ccline
~/.ccline/bash/install.shOne-liner (Windows PowerShell 5.1 or PowerShell 7+):
iwr -useb https://raw.githubusercontent.com/itzTiru/ccline/main/setup.ps1 | iexOr clone + install:
git clone https://github.com/itzTiru/ccline.git "$HOME\.ccline"
& "$HOME\.ccline\powershell\install.ps1"If your execution policy blocks unsigned scripts, run the installer as:
powershell -NoProfile -ExecutionPolicy Bypass -File "$HOME\.ccline\powershell\install.ps1"After install, press Esc in Claude Code to refresh the statusline. Run ccline config anytime to tweak segments.
- clones/copies repo to
~/.ccline(or wherever you cloned it) - copies the statusline script to
~/.claude/ccline-statusline.sh(bash) or~/.claude/ccline-statusline.ps1(PowerShell) - copies default
ccline.confto~/.claude/ccline.conf - backs up
~/.claude/settings.jsonto~/.claude/settings.json.ccline-backup - patches
settings.jsonso Claude Code'sstatusLineruns the new script - installs a
cclineshim into~/.local/bin(bash symlink, or.cmdwrapper on Windows)
ccline.conf shared default config
setup.sh curl | bash installer
setup.ps1 iwr | iex installer
bash/ ccline, install.sh, statusline.sh, uninstall.sh
powershell/ ccline.ps1, install.ps1, statusline.ps1, uninstall.ps1
ccline init install and activate
ccline config interactive toggle menu (save with q)
ccline gh <user> switch active GitHub account (wraps gh auth switch)
ccline aws [profile] list AWS profiles; with arg, print the profile name
ccline status show install state
ccline uninstall restore original settings.json, remove script
ccline help usage
Bash:
ccline config # toggle segments on/off
ccline gh myworkaccount # switch GitHub auth
eval $(ccline aws dev) # switch AWS profile in current shell
ccline uninstall # clean revertPowerShell:
ccline config # toggle segments on/off
ccline gh myworkaccount # switch GitHub auth
$env:AWS_PROFILE = (ccline aws dev) # switch AWS profile in current shell
ccline uninstall # clean revert~/.claude/ccline.conf is a plain key=value file shared by both the bash and PowerShell scripts. Edit directly or via ccline config.
SHOW_DIR=1
SHOW_GITHUB=1
SHOW_AWS=1
SHOW_MODEL=1
SHOW_COST=1
SHOW_CONTEXT=1
SHOW_GIT=0
SHOW_RATE_LIMIT=0
SHOW_DURATION=0
SHOW_LINES=0
CONTEXT_WARN=50 # yellow at this %
CONTEXT_ALERT=80 # red at this %
ccline displays cost.total_cost_usd as emitted by Claude Code itself. Claude Code computes this turn-by-turn from actual API usage responses. It's the most accurate figure available client-side. Color thresholds kick in at $1 (yellow) and $5 (red) per session.
Caveats that affect any statusline:
- Fast mode (Opus 4.6) bills at 6× standard rates. The statusline JSON does not expose fast-mode state directly, but Claude Code's cost figure still reflects it correctly.
- The 1M-context surcharge that used to apply above 200k tokens no longer exists for Opus 4.6 / Sonnet 4.6. Pricing is flat across the full window.
ccline uninstall- restores
settings.jsonfrom the backup made on firstinit - removes
~/.claude/ccline-statusline.sh(or.ps1) - removes the
~/.local/bin/cclineshim - keeps
~/.claude/ccline.conf(delete manually if you want it gone)
Bash edition (Linux / macOS / WSL / Git Bash):
bash3.2+ (macOS default works)jqawk,sed,grep,git(shipped everywhere Unix)ghCLI (only if you useccline gh)
PowerShell edition (Windows):
- Windows PowerShell 5.1 or PowerShell 7+ (
pwshpreferred when present) giton PATHghCLI (only if you useccline gh)
MIT