Files
Andre f2d2f1e1b9 feat: warn/critical context bar at 20/40 percent
The context bar colored at 40/70 percent, which on a 1M-token window only
turned yellow at 400k and red at 700k - far too late to warn before the
window fills. Percentage thresholds stay model-independent while mapping to
the intended 200k/400k marks on the current 1M window.
2026-07-18 16:16:37 +02:00

52 lines
1.5 KiB
TOML

# cship — Claude Code statusline (Hero / Recommended + usage progress bars)
# Reference: https://cship.dev
[cship]
lines = [
"$starship_prompt",
"$cship.model $cship.effort $cship.context_window.total_input_tokens $cship.context_bar $cship.peak_usage $cship.usage_limits",
]
[cship.model]
symbol = "🤖 "
style = "bold cyan"
[cship.effort]
symbol = "⚡ "
style = "fg:#7dcfff"
high_style = "fg:#e0af68"
xhigh_style = "bold fg:#e0af68"
max_style = "bold fg:#f7768e"
[cship.context_bar]
symbol = "🧠 "
filled_char = "█"
empty_char = "░"
format = "[$symbol$value]($style)"
width = 10
style = "fg:#7dcfff"
warn_threshold = 20.0
warn_style = "yellow"
critical_threshold = 40.0
critical_style = "bold red"
# $value is emitted inside a §T§…§ marker so the statusline wrapper can
# compact the raw token count (e.g. 42329 → 42.3K) before display.
[cship.context_window.total_input_tokens]
symbol = "🔢 "
style = "fg:#a9b1d6"
format = "[$symbol§T§$value§]($style)"
# usage_limits emits machine markers (§TYPE§pct§reset§); the statusline wrapper
# turns them into progress bars styled like context_bar. Thresholds >100 so cship
# adds no ANSI of its own around the markers.
[cship.usage_limits]
style = ""
separator = " "
five_hour_format = "§5§{pct}§{reset}§"
seven_day_format = "§7§{pct}§{reset}§"
warn_threshold = 101
critical_threshold = 101
[cship.peak_usage]
symbol = "⏰ "
style = "fg:#e0af68"