Skip to content

[Resource]: claude-code-usage-bar #1847

@leeguooooo

Description

@leeguooooo

Display Name

claude-statusbar

Category

Status Lines

Sub-Category

General

Primary Link

https://github.com/leeguooooo/claude-code-usage-bar

Author Name

leeguooooo

Author Link

https://github.com/leeguooooo

License

MIT

Other License

No response

Description

Python status-line for Claude Code. Shows 5-hour and 7-day rate-limit usage, reset countdowns, current model, context window, prompt-cache freshness, and optional per-session cost in one line. Three styles, nine themes, configurable via a cs CLI; daemon mode (default since v3.6.0) keeps CPU under 1% at sub-second refresh. Reads session data locally; the only network call is a once-per-24h PyPI version check that auto-upgrades the package, disabled by CLAUDE_STATUSBAR_NO_UPDATE=1.

Validate Claims

Install via pip install claude-statusbar, run cs --setup to wire the statusLine hook into ~/.claude/settings.json, then restart Claude Code. The bottom line of the terminal now shows live rate-limit usage bars and timers. Run cs preview to render every style × theme combination side-by-side using real cached data. Run cs doctor to validate the wiring and surface misconfiguration.

Specific Task(s)

Inspect Claude Code's current 5-hour rate-limit window without leaving the terminal, then switch the status bar to a different theme.

Specific Prompt(s)

"Show me my current 5h and 7d rate-limit usage and switch the status bar theme to nord." The claude-statusbar skill routes this to cs config set theme nord and reports the current usage from the cached headers.

Additional Comments

Disclosures per CONTRIBUTING guidance:

  • Auto-update (on by default): once per 24h, on status-line render, the tool checks https://pypi.org/pypi/claude-statusbar/json and, if a newer version exists, silently runs the appropriate upgrade command (pip/pipx/uv tool install --upgrade) capped at 60s. Disable via env CLAUDE_STATUSBAR_NO_UPDATE=1 or CLI flag --no-auto-update. Source: src/claude_statusbar/updater.py + core.py:check_for_updates.
  • Settings auto-repair (on by default): once per 24h, the tool calls ensure_statusline_configured() which atomically rewrites ~/.claude/settings.json if the statusLine hook is missing or points elsewhere. This is what makes pip install + restart Claude Code work without a manual cs --setup, but it means the package modifies a shared Claude Code config file outside the explicit setup command. Source: src/claude_statusbar/setup.py + core.py:_maybe_ensure_statusline.
  • Network: the PyPI version check is the only outbound request. No telemetry, no analytics, no calls to any author-controlled server.
  • Files written: ~/.claude/settings.json (one statusLine block, atomic write), ~/.claude/claude-statusbar.json (own config), ~/.cache/claude-statusbar/ (timestamp markers + daemon socket/render cache).
  • Daemon mode: opt-out long-lived background process for sub-second refresh, default since v3.6.0. Stop with cs daemon stop; pass --inline to cs --setup to opt out entirely.
  • No --dangerously-skip-permissions required; no sudo needed.
  • Uninstall: cs --uninstall removes the statusLine entry from ~/.claude/settings.json; pip uninstall claude-statusbar removes the package. To also remove caches: rm -rf ~/.cache/claude-statusbar ~/.claude/claude-statusbar.json.

Recommendation Checklist

  • I have checked that this resource hasn't already been submitted
  • It has been over one week since the first public commit to the repo I am recommending
  • All provided links are working and publicly accessible
  • I do NOT have any other open issues in this repository
  • I am primarily composed of human-y stuff and not electrical circuits

Metadata

Metadata

Assignees

No one assigned

    Labels

    resource-submissionThis Issue submits a new resource to the listvalidation-passedResource has passed initial validation

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions