feat(project-bootstrap): recommend superpowers plugin if missing

CLAUDE.md template adds `use superpowers` as a trigger, but that line
is silently dead until the official plugin is installed. New Step 5.6
reads ~/.claude/plugins/installed_plugins.json and, when the
`superpowers@claude-plugins-official` key is absent, prints a chat-only
recommendation with the install command and the upstream link
(github.com/anthropics/claude-plugins-official).

Strict no-auto-install: slash commands aren't callable from a skill,
and silent plugin install would be overreach.

Bumps project-bootstrap 1.0.0 → 1.1.0. Rebuilt dist archive.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-28 20:47:58 +03:00
parent 074cbe9065
commit d3a83a7d41
6 changed files with 94 additions and 3 deletions

View File

@@ -0,0 +1,34 @@
# bootstrap-recommend-superpowers
## Goal
`project-bootstrap` writes `use superpowers` into the new project's `CLAUDE.md` (Step 5 template), but that trigger only fires if the `superpowers@claude-plugins-official` plugin is installed. On a fresh machine the plugin is often absent, so the trigger silently no-ops. Add a Step 5.6 that detects the plugin via `~/.claude/plugins/installed_plugins.json` and, when missing, prints a recommendation with the exact install command + upstream link. Strictly informational — never auto-installs.
## Key files
- `skills/project-bootstrap/SKILL.md` — add Step 5.6 between 5.5 (manifest) and 6 (commit); bump frontmatter `version: 1.0.0 → 1.1.0`
- `skills/project-bootstrap/README.md` — extend the steps overview to mention the new check
- `~/.claude/plugins/installed_plugins.json` — detection source
## Decisions log
- 2026-04-28: Place check at Step 5.6 (right after manifest, before commit). Reason: CLAUDE.md just got `use superpowers`, so the recommendation lands while context is fresh. Alternative — fold into Step 0 detect — rejected: Step 0 is meant to be quick + read-only summary; threading plugin checks there bloats the no-op happy path.
- 2026-04-28: Detection by file read, not by `/plugin list`. Reason: slash commands aren't callable from inside a skill; the JSON file is the source of truth Claude Code itself reads. Same approach as `setup-context7` Phase 1.
- 2026-04-28: Recommendation, not auto-install. Reason: `/plugin install` is interactive and per `setup-context7` we can't drive slash commands from a skill. Even if we could, auto-installing a plugin without consent is overreach.
- 2026-04-28: Limit scope to `superpowers` only. User explicitly asked for that one. Generic "recommended plugins" framework is feature creep — defer until there's a second item.
## Open questions
- [ ] None — done.
## Completed steps
- [x] Confirm plugin install path / JSON shape from local `installed_plugins.json`
- [x] Pick insertion point (Step 5.6)
- [x] Pick detection method (file read of `installed_plugins.json`)
- [x] Patch `SKILL.md` (Step 5.6 + frontmatter `version: 1.1.0`)
- [x] Update `README.md` workflow numbering
- [x] Reinstall to `~/.claude/skills/project-bootstrap/`
- [x] Rebuild `dist/project-bootstrap.skill`
- [x] Append wiki log entry
- [x] Commit
## Notes
- Plugin install command (canonical, from `installed_plugins.json` key): `/plugin install superpowers@claude-plugins-official`
- Upstream: https://github.com/anthropics/claude-plugins-official
- Cross-platform path: `~/.claude/plugins/installed_plugins.json` resolves identically on Windows / Linux / macOS.