Commit Graph

8 Commits

  • feat: show output speed as last response with window average
    - speed: replace input/output pair with two output speeds
    - last single response speed, window average in parentheses
    - format: "↓ 74.3 (120.5) t/s"
  • feat: hide segments with no data instead of showing placeholders
    - git/speed/rate return an empty string when they have no real data
    - render() skips empty parts along with their separators, so an absent segment leaves no dangling `|`
    - avoids the startup row of placeholders (`| - | ↑ — ↓ — t/s | -`), collapsing the line to only the segments that actually have data
  • refactor: optimize git/transcript sources, centralize colors, add tests
    - git: fetch branch and changed files in one `git status --porcelain --branch` (3 subprocesses -> 2)
    - transcript: read only the last 1 MB from the file tail instead of parsing the whole jsonl
    - color: add a shared palette and route heat() and every widget through it
    - widgets: drop the preview bridge functions; preview now calls the component fns directly
    - add unit tests for the pure helpers (parse_branch, interval merge, heat, percentages, formatting)
  • fix: make statusline work cleanly on Linux too
    - install: only convert backslashes to slashes on Windows (backslash is a valid char in Unix paths)
    - config dir resolution already falls back from USERPROFILE to HOME, covering both platforms
    - README: cross-platform build/install instructions, recommend the install command
  • feat: add install command to configure statusLine in settings.json
    - locate Claude config via CLAUDE_CONFIG_DIR or ~/.claude
    - scope arg: user (default), project, or local
    - preserve existing settings and key order; back up to .bak
    - set statusLine command to the quoted current executable path (handles spaces)
  • docs: add README and adjust rate separator
    - add concise Chinese README
    - rate: use "-" instead of "/" between 5h/7d usage
  • feat: implement Rust statusline for Claude Code
    - parse status JSON from stdin and render a single status line
    - widgets: model+thinking, context %, directory, git, token speed, rate limits
    - coloring: green-to-red gradient plus fixed per-widget colors
    - `test` subcommand previews all widgets with synthetic data
    - braille-blank placeholder on the second line