Skip to content

0.3.0

Latest

Choose a tag to compare

@devnix devnix released this 30 Oct 23:48
· 2 commits to main since this release
3e3abf2

Upgrade notes

  • Restart Claude Code after the upgrade. The hooks and the statusline change together, and Claude Code loads them at startup.
  • New network requests:
    • {miss} and {next} download the prices from models.dev once a day. BURNBAR_FRESH_PRICES=0 turns this off.
    • {monthly} and {daily} call api.anthropic.com/api/oauth/usage every 5 minutes with your Claude Code OAuth token. This is the undocumented endpoint behind /usage. On macOS the token comes from the login Keychain. Remove both tags from BURNBAR_FORMAT to turn this off.
  • The default format is longer. It adds {monthly}, {daily}, {5h} and {1w}, and shows {miss} in place of {next}. A format that you set in BURNBAR_FORMAT does not change.
  • The default bars are narrower. BURNBAR_BAR_WIDTH is 20 (was 30) and BURNBAR_CACHE_WIDTH is 8 (was 10). Set them to keep the old widths.
  • {next} shows a different number. It is now an alias of {miss}, the cost of a cache miss.

Added

  • {miss}: what the next message costs on a cache miss, the whole context written to the cache again. It turns red when the cache has expired. Prices refresh daily from models.dev, and the built-in table stays the fallback (#9) (thanks @lunetics!)
  • {monthly} and {daily}: billed spend from your plan, in the account's currency. {monthly} shows a bar against the plan limit, and BURNBAR_MONTHLY_BUDGET applies when the plan has none. BURNBAR_DAILY_BUDGET adds a bar to {daily}. A reading older than 15 minutes shows a ~ before the amounts (#10).
  • {5h} and {1w}: plan-usage meters, with reset times. Pro and Max plans only.
  • {sep} and {wrap}: separators that become a line break when the line does not fit, and optional groups: [[cache: {cache}]] removes the label when the tag is empty.
  • An effort icon next to the model name in {model}.
  • BURNBAR_CACHE_WIDTH=0 hides the cache bar and keeps the countdown (#7).
  • BURNBAR_NOTIFY_LEAD: seconds before expiry for the cache notification. The default is 5 minutes, capped at half the TTL.
  • Support for the stock macOS bash 3.2.

Changed

  • The cache timer knows the TTL of the session, 5 minutes or 1 hour, from the transcript. Until it knows, it shows --:--, sends no notification and leaves {miss} empty (#11).
  • The timer restarts only when a response read or wrote the cache, and counts from the start of that request. A prompt does not restart it. While a request runs, the countdown can be low until the response arrives, and it is never high (#11).
  • 00:00 flashes when the cache has expired (#7).
  • {delta} and the last {spark} column grow with the current turn (#6).
  • ⚠ effort shows only on the models where an effort change rewrites the cache. ⚠ model compares the model version, not the family (#8).

Fixed

  • A 1-hour cache no longer shows a 5-minute countdown (#11).
  • A subagent no longer restarts the main countdown (#11).
  • An & in a value, such as the working directory, no longer breaks the line on bash 5.2 and later.

Full Changelog: 0.2.2...0.3.0