feat: setup-context7 skill + using-context7 prerequisites pointer
Split context7 concerns into two skills: - using-context7 (policy, every-time): when to call, how to query well - setup-context7 (infrastructure, one-time): install plugin, inject API key, clean manual MCP entries, with confirmation gates setup-context7 reuses an existing CONTEXT7_API_KEY by searching, in order: ~/.claude/settings.json → ~/.claude.json (top-level + project-scoped) → ~/.claude/settings.local.json → env. Asks the user only if nothing found. Cross-platform (paths identical on Win/Linux/macOS; only JSON validator differs). Phase-2 confirmation gate before any write; per-edit JSON validation; rollback procedure documented. using-context7 gets a small Prerequisites section pointing at setup-context7 when MCP tools are missing. Bonus fix: scripts/build.sh PS multi-arg bug. Comma-joined -Names didn't split into [string[]] when build.ps1 was invoked via -File. Now the bash side loops one PS invocation per skill. Wiki: extended .wiki/concepts/context7-setup.md with the design rationale (why split policy from setup) — template for future "X plugin + how to use X" pairs. index.md and log.md updated. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -3,6 +3,16 @@ _Updated: 2026-04-28_
|
||||
|
||||
## Done
|
||||
|
||||
### Create `setup-context7` skill
|
||||
- [x] Drafted `skills/setup-context7/SKILL.md` — 8 phases (discovery → plan → backup → install → inject → clean → smoke-test → restart) + rollback + cross-platform notes
|
||||
- [x] API-key discovery in priority order: `settings.json` → `.claude.json` (top-level + project-scoped) → `settings.local.json` → env → ask
|
||||
- [x] Phase 2 confirmation gate (no mutations without explicit "ok"); Phase 6 validates JSON after each edit
|
||||
- [x] Documented `/plugin update` gotcha
|
||||
- [x] Added Prerequisites section in `using-context7` pointing at `setup-context7`
|
||||
- [x] Built + installed both skills (`setup-context7` already in `available_skills`)
|
||||
- [x] Updated `.wiki/concepts/context7-setup.md` with "Now captured as a skill" section explaining the policy/setup split rationale
|
||||
- [x] **Bonus fix:** `scripts/build.sh` PS multi-arg bug — comma-joined `-Names` wasn't splitting into `[string[]]` when called via `-File`. Now loops in bash, one PS invocation per skill.
|
||||
|
||||
### Switch context7 from manual MCP config to official plugin
|
||||
- [x] Backup `~/.claude.json` and `~/.claude/settings.json` (suffix `.bak-20260428-114532`)
|
||||
- [x] User installed `context7@claude-plugins-official`
|
||||
|
||||
Reference in New Issue
Block a user