Commit bb873ee
authored
docs(rules): fix stale 5-plugin claims and make plugin inventory drift-resistant (#557)
* docs: fix stale 5-plugin claims and make inventory drift-resistant
.claude/rules/plugin-docs.md is loaded into every session's context, so its
"## The 5 Plugins" section was actively steering plugin work away from
claude-setup, skill-management, and spec-workflow. The repo has had 8 plugins
for some time; the root CLAUDE.md already said 8, so the two contradicted
each other.
Rather than just correcting 5 to 8 (which drifts again on the next addition),
both files now name packages/plugins/ and .claude-plugin/marketplace.json as
the source of truth, give an enumeration command, and state that the
enumerated output wins over the inline snapshot.
- plugin-docs.md: rewrite "The 5 Plugins" as "The Plugins" with a
source-of-truth block, an enumeration command, a one-line parity check
between the directories and marketplace.json, and a dated snapshot that
readers are told to repair on mismatch
- plugin-docs.md: "Each of the 5 plugins has its own section" -> "Each plugin"
- CLAUDE.md: same de-hardcoding for the inventory bullet and the same
"Each of the 5 plugins" phrasing in the Notion sync section
Left .plan/DEV-218-implementation.md alone: its "5 plugins" is a point-in-time
justification in a completed migration plan, and rewriting it would make it
wrong about the state it describes.
No files under packages/plugins/ changed, so no plugin version bump applies.
* docs: check marketplace source paths, not just names, in parity check
The parity check compared .plugins[].name against the directory names. That
passes even when an entry's `source` is stale or copy-pasted, because `name`
is not the field that determines what loads.
.github/actions/validate-plugins/action.yml:64-71 resolves .plugins[i].source
into PLUGIN_PATH and validates that path; `name` is only used for log output.
So an entry named `foo` whose source still points at `./packages/plugins/
skill-management` makes the validator check skill-management twice while `foo`
goes unreferenced - and the old check certified that as parity.
Reproduced against a scratch fixture: names-vs-dirs passed, sources-vs-dirs
caught it.
Replaced with two checks: (1) resolved source paths against the directories on
disk, (2) each entry's name against its own source basename. Both verified
silent against the current marketplace.json, and executed verbatim as
extracted from the rendered file to confirm the jq escapes survive prettier.1 parent 7aa69ca commit bb873ee
2 files changed
Lines changed: 43 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
| 19 | + | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
40 | 40 | | |
41 | | - | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
42 | 44 | | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
48 | 80 | | |
49 | 81 | | |
50 | 82 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
166 | | - | |
| 166 | + | |
| 167 | + | |
167 | 168 | | |
168 | 169 | | |
169 | 170 | | |
| |||
364 | 365 | | |
365 | 366 | | |
366 | 367 | | |
367 | | - | |
| 368 | + | |
368 | 369 | | |
369 | 370 | | |
370 | 371 | | |
| |||
0 commit comments