Release grok-build-hud v0.3.0: Claude-HUD-style same-window status for Grok Build
Multi-line tmux strip (context, quota, tools, todos, git), theme sync with Grok UI, full/essential/minimal presets, one-shot installer, EN+ZH docs, and 40 unit tests.
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
---
|
||||
description: Show live context window + quota bars (Claude-HUD style)
|
||||
---
|
||||
|
||||
# /hud — live context + quota
|
||||
|
||||
Print the multi-line HUD for the active Grok session:
|
||||
|
||||
```bash
|
||||
grok-hud status
|
||||
# or:
|
||||
grok-build-hud --once --follow-active --no-color
|
||||
```
|
||||
|
||||
If CLIs are not on PATH (plugin-only install):
|
||||
|
||||
```bash
|
||||
node "${GROK_PLUGIN_ROOT}/bin/grok-build-hud.js" --once --follow-active --no-color
|
||||
```
|
||||
|
||||
Example:
|
||||
|
||||
```text
|
||||
[Grok 4.5] │ my-project git:(main*) │ ● LIVE
|
||||
Context ████████░░ 78% (392k/500k) │ Quota ██░░░░░░░░ 24% weekly · 4d
|
||||
◐ read_file… | ✓ grep ×3
|
||||
```
|
||||
|
||||
For always-on same-window strip: start with `grok-hud-run` (not a second window).
|
||||
@@ -0,0 +1,23 @@
|
||||
---
|
||||
description: Set Claude-HUD-style HUD preset (full / essential / minimal)
|
||||
---
|
||||
|
||||
# HUD presets (Claude HUD parity)
|
||||
|
||||
```bash
|
||||
# Full — model, git, context+usage dual bars, tools, agents, todos, diff stats (3 rows)
|
||||
grok-build-hud --preset full
|
||||
# or: grok-hud preset full
|
||||
|
||||
# Essential — dual bars + activity (2 rows)
|
||||
grok-build-hud --preset essential
|
||||
|
||||
# Minimal — single dense row
|
||||
grok-build-hud --preset minimal
|
||||
```
|
||||
|
||||
Then refresh tmux (if already in a HUD session):
|
||||
|
||||
```bash
|
||||
tmux source-file ~/.grok/hud/tmux.conf && tmux refresh-client -S
|
||||
```
|
||||
@@ -0,0 +1,13 @@
|
||||
---
|
||||
description: Show account quota / credit usage (weekly + monthly)
|
||||
---
|
||||
|
||||
# /quota
|
||||
|
||||
```bash
|
||||
grok-hud status
|
||||
```
|
||||
|
||||
Look for the **Quota / Usage** line (weekly % · monthly used/limit · GrokBuild share).
|
||||
|
||||
Official panel inside Grok: `/usage`.
|
||||
@@ -0,0 +1,45 @@
|
||||
---
|
||||
description: Install grok-build-hud dashboard + same-window multi-line status
|
||||
---
|
||||
|
||||
# grok-build-hud setup
|
||||
|
||||
One-time setup (from the plugin / repo root):
|
||||
|
||||
```bash
|
||||
npm install && npm run build
|
||||
# Preferred: full same-window HUD (tmux multi-line strip)
|
||||
node bin/grok-build-hud.js --install-dashboard
|
||||
node bin/grok-build-hud.js --theme auto
|
||||
node bin/grok-build-hud.js --preset full
|
||||
```
|
||||
|
||||
Or: `bash scripts/install.sh` / `npm run install-local`.
|
||||
|
||||
## Start Grok with HUD (same Terminal tab)
|
||||
|
||||
```bash
|
||||
grok-hud-run
|
||||
```
|
||||
|
||||
You should see **2–3 rows** at the bottom (context + usage bars), not a second window.
|
||||
|
||||
## Hooks only (scrollback annotations)
|
||||
|
||||
```bash
|
||||
node bin/grok-build-hud.js --install-hooks
|
||||
```
|
||||
|
||||
Reload in Grok: `/hooks` then press `r`.
|
||||
|
||||
Example annotation:
|
||||
|
||||
```text
|
||||
[hud] ctx 30% 154k/500k │ turns 3 │ tools 78 │ live │ project
|
||||
```
|
||||
|
||||
## Verify
|
||||
|
||||
```bash
|
||||
grok-hud status
|
||||
```
|
||||
@@ -0,0 +1,17 @@
|
||||
---
|
||||
description: Show one-shot grok-build-hud snapshot
|
||||
---
|
||||
|
||||
# /status — one-shot HUD
|
||||
|
||||
```bash
|
||||
grok-hud status
|
||||
# or:
|
||||
grok-build-hud --once --follow-active --no-color
|
||||
```
|
||||
|
||||
For the always-on same-window bar (recommended):
|
||||
|
||||
```bash
|
||||
grok-hud-run
|
||||
```
|
||||
@@ -0,0 +1,31 @@
|
||||
---
|
||||
description: How to keep the HUD live (same-window recommended)
|
||||
---
|
||||
|
||||
# Live HUD
|
||||
|
||||
## Recommended: same Terminal window
|
||||
|
||||
```bash
|
||||
grok-hud-run
|
||||
```
|
||||
|
||||
Starts Grok with a permanent multi-line status strip at the bottom (tmux). **No second window.**
|
||||
|
||||
## Optional: external watch in another pane
|
||||
|
||||
```bash
|
||||
grok-build-hud --watch --follow-active --cwd "$(pwd)"
|
||||
```
|
||||
|
||||
Short capture / tests:
|
||||
|
||||
```bash
|
||||
grok-build-hud --watch --max-iterations 3 --interval 500
|
||||
```
|
||||
|
||||
Single tmux status line (legacy):
|
||||
|
||||
```bash
|
||||
grok-build-hud --tmux --no-color
|
||||
```
|
||||
Reference in New Issue
Block a user