v0.3.1
Added
-
preview— draw your statusline in a terminal, without restarting OpenCode.
bunx @opencode-cockpit/status preview --watchredraws on every save, against six sample
sessions: a fresh one before the first reply, a long one nearly out of room, one behind a proxy
with nothing declared, a stalled one, and no session at all. Designing a statusline used to mean
editing, restarting and squinting — one sidebar cost about twenty restarts, and three of the
mistakes were glyph choices that read differently on screen than in a sentence. -
"debug": truedraws a placeholder where a segment said nothing, so the three reasons a
segment can be absent stop looking identical:⟨context⟩it ran and had nothing to say,
⟨?contex⟩nothing answers to that name,⟨!name⟩it threw. -
A segment can return several rows. An array is a row each, which is how a gauge, a table or a
row per service is drawn. Returning one used to be a silent no-op. -
italicandunderlineon a run, drawn as markup.strikethroughandinverseare not
offered: OpenTUI has no element for either, so they could never have reached the screen. -
examples/gallery.ts— every technique the renderer offers in one column: six kinds of bar,
braille, sparklines, rules, dots, chips, dividers, emphasis, every tone, and multi-row output.
Run it throughpreviewand copy the row you want. -
A design skill, shipped with the package at
skills/statusline-design/, carrying the rules
this bay learned the expensive way — solid bars rather than dashes, words rather than colour
alone, no headings above optional rows, look at it before shipping it. -
Presets — a whole line by name, built-ins only:
minimal,default,detailed,sidebar.
Anything written beside one wins, so it is a starting point rather than a mode. -
examples/sidebar-budget.ts— a sidebar drawn as a table, and the layout a user arrived at
after five rejected iterations: a fixed six-column label gutter so every value lines up, one bar
with no figure beside it, the tokens split into named rows, a budget read from whatever a proxy
writes to~/.cache/opencode-litellm-iap/spend.json, and the branch's whole diff against its
merge-base rather than what this session happened to touch."demo": truefills in sample
figures for the budget rows, so the column can be looked at before a proxy exists.
Fixed
- A statusline module that fails to load now says so in OpenCode's log, not only in a toast
that is gone in ten seconds. The entry names both the module and the directory resolution was
attempted from, which is the pair that makes an import failure obvious instead of mysterious. maxRowsand the padding settings work at the top level of the config, not only inside a
linesentry. Writing them there is the natural guess, and being quietly ignored cost exactly
the rows they were meant to keep.
Documentation
- The design skill is documented on the site, at What you can draw — where it ships, how to
point an agent at it, and what it actually carries. It existed in the package and was mentioned
only in this file, which is no way to find anything. - Two glyph traps written down:
▕and▏are eighth-blocks whose ink sits against one edge
of the cell, so end caps indent a column's bar out of alignment with its labels; and an empty
track wants a solid█in thebordertone, because░reads as floating gaps andpanelis
the colour of the panel it sits on. - The worked-examples lists name all five modules. They still said two.