Add Skills widget with cross-platform hook framework#201
Merged
sirmalloc merged 4 commits intosirmalloc:mainfrom Mar 5, 2026
Merged
Conversation
Replaces bash/jq hook with a built-in --hook CLI handler that works on all platforms. Widgets can declare hooks via getHooks() which are auto-synced to Claude settings when the statusline config is saved.
c9f6a28 to
89f2558
Compare
4 tasks
Owner
|
Nice, I like how this is architected. Let me dig into it either tonight or tomorrow and I should be able to test and publish a build with it. I'll go ahead and close the previous PR. |
Notes:\n- Hook sync now follows saved-state semantics: installing statusline syncs hooks from saved ccstatusline settings on disk, and uninstall always removes all ccstatusline-managed hooks.\n- syncWidgetHooks always strips managed hooks first, including when statusline.command is missing, then persists cleanup.\n- Skills metrics storage path is now ~/.cache/ccstatusline/skills/skills-<sessionId>.jsonl.\n- Skills unique list ordering is now most-recent-first.\n- Skills widget updates: view toggle on (v), hide-when-empty toggle on (h), explicit empty outputs when not hidden, and new list-only (l)imit editor option where 0 means unlimited (default).\n- Added list-limit custom editor flow and list-only keybind visibility in ItemsEditor.\n- Maintained Node 14 compatibility by avoiding Array.prototype.at in skills metrics parsing.\n- Added/updated regression tests for hook sync/install/uninstall behavior, skills metrics path/order, Skills widget rendering/editing, and items-editor custom keybind handling.
Owner
|
Thanks for this. Did some bug fixes and added some enhancements. Will publish shortly. |
8 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Supersedes #163. Addresses feedback:
ccstatusline --hook(Node/Bun, works on Windows)getHooks(), auto-synced to~/.claude/settings.jsonon save (taggedccstatusline-managedfor clean install/uninstall)mkeybindHow it works
Widget declares hooks →
saveSettings()syncs them to Claude config → Claude callsccstatusline --hook→ parses stdin, appends to JSONL → widget reads JSONL on render.Test plan
tsc --noEmitpasseseslintpassesvitest— no new failures/commit→ widget displays it