Skip to content

feat(statusline): draw everything claude-hud's default draws by default - #613

Merged
Mearman merged 2 commits into
mainfrom
feat/statusline-superset
Oct 27, 2026
Merged

Mearman merged 2 commits into
mainfrom
feat/statusline-superset

Conversation

@Mearman

@Mearman Mearman commented Oct 27, 2026

Copy link
Copy Markdown
Member

The built-in statusline's default now draws everything stock claude-hud's default draws, then agent-shim's own segments, so a launch with no statusline settings is a superset of claude-hud's. The header lists the model with the platform label beside it, the project with its git status and added directories inline, the provider and route, the login account, the identity, headroom's savings and the extra segment (which draws nothing until extra.command is set). The rows are the context window, the quota windows and an added directories row that draws nothing while the directories are inline.

The defaults follow claude-hud's. The reset label and the per-model weekly windows are on, the weekly window is hidden below 80% of its use when a five-hour window is drawn beside it, the token breakdown appears from 85% of the context window, a context estimate with the autocompact reserve is made when the client reports no percentage, and the model is named by its id when the client sends no display name. The context bar has thresholds of its own, context.warnAt and context.criticalAt at 70 and 85 and apart from bands, with context.breakdownAt for the breakdown. A Bedrock session draws no subscription window. Because the default quota block is wider, at some widths the context bar and the quota windows now each align within themselves where the previous default lined them up on one grid.

This is a deliberate change to the default output, so it is a minor release and not a breaking one. To get the previous output back, set layout.header to model, provider, route, account, identity and headroom, layout.rows to context and quota, usage.resetLabel, usage.modelScoped and model.platform to false, usage.sevenDayThreshold to 0, context.estimate and context.breakdown to never, and context.criticalAt to 90. A few things follow the session and not a preference and are not undone by those settings, such as the Bedrock rule and comparing the whole-number percentage with the thresholds as claude-hud does; the configuration model and the parity doc list them.

The behaviour is documented in the configuration model and the CLI reference, and docs/statusline-claude-hud-parity.md records every default taken from claude-hud and every difference kept. Refs #565.

The default statusline now draws everything stock claude-hud's default
configuration draws, then agent-shim's own segments, so a launch with no
statusline settings is a superset of claude-hud's. The header lists the
model with the platform label beside it, the project with its git status
and added directories inline, the provider and route, the login account,
the identity, headroom's savings and the extra segment, which draws
nothing until extra.command is set; the rows are the context window, the
quota windows and an added directories row that draws nothing while the
directories are inline.

The defaults follow claude-hud's: the reset label and the per-model weekly
windows are on, the weekly window is hidden below 80% of its use when a
five-hour window is drawn beside it, the token breakdown appears from 85%
of the context window, a context estimate with the autocompact reserve is
made when the client reports no percentage, and the model is named by its
id when the client sends no display name. The context bar has thresholds of
its own, context.warnAt and context.criticalAt, at claude-hud's 70 and 85
and apart from bands, with context.breakdownAt for the breakdown. The
context thresholds and the usage thresholds that hide a window are compared
against the percentage rounded to a whole number, as claude-hud compares
them, and the context bar's gradient stops sit half a point below its
thresholds, where that comparison places them.

The wider default quota block no longer fits on one grid with the context bar
at some widths, and there the context bar and the quota windows each align
within themselves, where the previous default lined them up wherever it
fitted them on one grid.

A session served through Bedrock draws no subscription window. A per-model
window with a null figure is drawn as claude-hud draws it, and one with a
missing or non-numeric figure is drawn too, where claude-hud skips it. The
platform is read only for a Claude Code client, a negative token total or
reported percentage is read as absent and one above 100 is drawn as 100,
and a layer that sets only one of the context thresholds is refused when
it would leave them out of order. A per-model window keeps the 64
characters of its name claude-hud keeps, holds its figure between 0 and
100, and an added directory or per-model window the client sends that
cannot be used is skipped on its own, not discarding the rest of its
list. A group of bars that does not fit one to a row with its labels and
figures padded to match is drawn with each row aligned within itself, so
a long per-model name widens its own row and not the five-hour and weekly
ones.

The cache hit share's mirrored bands compare the share with the decimals
(100 less each threshold) / 100 themselves, so a share exactly on a
whole-percentage edge is on the side of the band it reaches. A quota
window's use is rounded to a whole percentage from the percentage it was
reported as, so a half such as 56.5 reaches the threshold 57 as it does in
claude-hud.
Document the default statusline in the configuration model, the CLI
reference and the architecture overview: what the default header and
rows draw, which defaults differ from the previous ones and the
setting that restores each, the context thresholds and the breakdown
threshold with their rounding, the Bedrock session and the platform
label, the conditions under which a quota window is hidden or drawn,
and how the bars lose alignment as the line narrows.
@Mearman
Mearman marked this pull request as ready for review October 27, 2026 00:35
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 27, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
🔒 Security Review ✅ Completed 2026-10-27T00:41:16.596983Z a94ef6e Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@Mearman
Mearman merged commit 9c69db7 into main Oct 27, 2026
32 checks passed
@Mearman
Mearman deleted the feat/statusline-superset branch October 27, 2026 00:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant