Gbrain skillpack-check
install
source · Clone the upstream repo
git clone https://github.com/garrytan/gbrain
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/garrytan/gbrain "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/skillpack-check" ~/.claude/skills/garrytan-gbrain-skillpack-check && rm -rf "$T"
manifest:
skills/skillpack-check/SKILL.mdsource content
Skillpack Check
Contract
Running
gbrain skillpack-check returns a JSON report with:
(bool): true if no action needed.healthy
(string): one-line summary safe to quote in a briefing.summary
(string[]): every remediation command. If non-empty, run them.actions
: fulldoctor
output (filesystem checks).gbrain doctor --fast --json
: applied/pending/partial counts frommigrations
.apply-migrations --list
Exit code:
— healthy, nothing to do.0
— action needed. Read1
and execute.actions[]
— could not determine (binary crash or missing subcommand). Investigate.2
When to run
- Daily cron (e.g. Wintermute's
):morning-briefing
. Exit code alone tells you if anything is wrong; surface a one-liner in the briefing only when exit != 0. No JSON noise in happy-path briefings.gbrain skillpack-check --quiet - On demand:
for the full JSON when debugging.gbrain skillpack-check - In a CI pipeline: same pattern — exit code gates, JSON is the evidence.
What to do with the output
Happy path (healthy: true
)
healthy: trueSurface the summary in the agent's output only if asked. Nothing else.
Action needed (healthy: false
)
healthy: falseThe
actions[] array contains the commands to run, in order. Execute them:
for cmd in $(echo "$REPORT" | jq -r '.actions[]'); do eval "$cmd" done
Common
actions[] entries and what they mean:
— A migration is pending or half-finished. Run this (it's idempotent). If it exitsgbrain apply-migrations --yes
, the host has non-builtin cron handlers that need plugin registration — followstatus: "partial"
.skills/migrations/v0.11.0.md
— Embeddings are stale.gbrain embed --stale
— Dead links or missing back-links.gbrain check-backlinks --fix- Free-text action (no
prefix in the source message) — agent judgment needed. Quote it in the report for the user.Run:
Determine failure (exit 2
)
exit 2Treat as urgent. Probably means the gbrain binary is missing from
$PATH or
a required subcommand crashed. Check:
returns a pathwhich gbrain
exits 0gbrain --version
is accessible~/.gbrain/
Output format
{ "version": "0.11.1", "ts": "2026-04-18T12:34:56.789Z", "healthy": false, "summary": "gbrain skillpack needs attention: 1 action(s) — gbrain apply-migrations --yes", "actions": ["gbrain apply-migrations --yes"], "doctor": { "exit_code": 1, "checks": [ { "name": "minions_migration", "status": "fail", "message": "MINIONS HALF-INSTALLED (partial migration: 0.11.0). Run: gbrain apply-migrations --yes" } ] }, "migrations": { "applied_count": 0, "pending_count": 0, "partial_count": 1, "stdout": "..." } }
Anti-Patterns
- ❌ Running without
in a cron that emails its output — you'll get the full JSON blob in every daily email. Use--quiet
in crons.--quiet - ❌ Ignoring exit code 2. A crashed doctor is worse than a failing check because you don't even know what's wrong.
- ❌ Running on every chat turn. Once per hour (or on user request) is plenty.
- ❌ Treating warnings as failures. Only
status needs action;fail
is informational.warn
Output Format
The skill itself doesn't write files; it reports the CLI output verbatim to the user (or to the agent's briefing pipeline). One-line summary first, then the action list, then (only if relevant) the full JSON for debugging.
Related
— the underlying filesystem + DB check. skillpack-check composes this.gbrain doctor
— the migration status view.gbrain apply-migrations --list
— the host-agent instruction manual for resolvingskills/migrations/v0.11.0.md
items.pending-host-work.jsonl
— troubleshooting a half-migrated install.docs/guides/minions-fix.md