diff --git a/setup-gbrain/SKILL.md b/setup-gbrain/SKILL.md index 9fdf8118e..a019d912a 100644 --- a/setup-gbrain/SKILL.md +++ b/setup-gbrain/SKILL.md @@ -925,9 +925,16 @@ gbrain is one of THREE code-intelligence providers gstack can use; the offer gate decides whether this repo is even worth indexing: ```bash -bun ~/.claude/skills/gstack/bin/gstack-code-intelligence suggest --json +[ -f ~/.claude/skills/gstack/bin/gstack-code-intelligence ] \ + && bun ~/.claude/skills/gstack/bin/gstack-code-intelligence suggest --json \ + || echo '{"offer": false, "reason": "bin-absent"}' ``` +- `"offer": false` with reason `bin-absent` → the installed gstack predates + the code-intelligence CLI. Skip this step entirely and continue with the + skill — the user asked for gbrain, so set up gbrain. Never block setup on + a missing optional gate. + - `"offer": false` with reason `small-repo` → grep is already fast here; say so in one line and continue with this skill only if the user asked for gbrain by name. diff --git a/setup-gbrain/SKILL.md.tmpl b/setup-gbrain/SKILL.md.tmpl index 83ac8575e..dc7f53183 100644 --- a/setup-gbrain/SKILL.md.tmpl +++ b/setup-gbrain/SKILL.md.tmpl @@ -167,9 +167,16 @@ gbrain is one of THREE code-intelligence providers gstack can use; the offer gate decides whether this repo is even worth indexing: ```bash -bun ~/.claude/skills/gstack/bin/gstack-code-intelligence suggest --json +[ -f ~/.claude/skills/gstack/bin/gstack-code-intelligence ] \ + && bun ~/.claude/skills/gstack/bin/gstack-code-intelligence suggest --json \ + || echo '{"offer": false, "reason": "bin-absent"}' ``` +- `"offer": false` with reason `bin-absent` → the installed gstack predates + the code-intelligence CLI. Skip this step entirely and continue with the + skill — the user asked for gbrain, so set up gbrain. Never block setup on + a missing optional gate. + - `"offer": false` with reason `small-repo` → grep is already fast here; say so in one line and continue with this skill only if the user asked for gbrain by name.