feat(gate): install truth, honest badges anywhere, and two stripCode bugs
Install truth is the brief's first control and the gate only checked syntax. Now: the marketplace URL must be the real one (offline, from the register), and the plugin must actually be pinned in the catalog (one call, SKIP if unreachable). A well-formed `claude plugin install x@mkt` fails silently when x was never pinned. This makes the gate block ITSELF until publication finishes - the run against this repo now has exactly one ERROR, and it is true: repo-standard is not in the catalog yet. That is the post-publish acceptance test, enforced mechanically instead of remembered. Badge honesty no longer keys on img.shields.io. A self-hosted SVG asserts the same unverified thing, and the README claimed the general rule while the code checked one host. Two stripCode bugs, both silent false passes: - 4-space indent treated as code unconditionally made links inside nested list items invisible. Fixed by requiring a blank line to OPEN a block. - That fix alone ended the block after line 1, so multi-line indented templates leaked back into scanning. Caught by the gate on this repo's own SKILL.md, which shows a README template containing a CHANGELOG link. A block now opens on a blank line and continues while the indent holds. Also corrected two claims in this README: it said "one network call" when there are two, and it still argued against a CONTRIBUTING using reasoning the solo-maintainer section had already replaced. 77 tests. llm-security regression: still zero link and boilerplate noise. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WYJ3FHLtVgzFXMZ6UF598h
This commit is contained in:
parent
720850a9ad
commit
6b1db0096e
5 changed files with 187 additions and 16 deletions
19
README.md
19
README.md
|
|
@ -41,9 +41,10 @@ a replacement for the two commands above:
|
|||
|
||||
## Requirements
|
||||
|
||||
Node 18 or newer. No dependencies. The one network call — the org listing, used
|
||||
to read a repo's published description — reads anonymously, so it needs no
|
||||
token; `--offline` skips it.
|
||||
Node 18 or newer. No dependencies. Two network calls: the org listing (for a
|
||||
repo's published description) and the catalog manifest (to confirm the install
|
||||
command resolves). Both read anonymously, so no token is needed, and `--offline`
|
||||
skips both — the checks that depended on them then report `SKIP`, not `OK`.
|
||||
|
||||
## What it does
|
||||
|
||||
|
|
@ -58,13 +59,14 @@ The repository's **class** decides what each check means:
|
|||
| Check | What fails it |
|
||||
| --- | --- |
|
||||
| First screen | no H1 on line 1, or the line under it is not the published description. An H1 that merely differs from the repo name is a `WARN` — that is a naming choice, not a defect |
|
||||
| Install block | the form for this class is missing, incomplete, or shown over `ssh://` |
|
||||
| Install block | the form for this class is missing, incomplete, shown over `ssh://`, or points at the wrong marketplace |
|
||||
| Install truth | the plugin is not pinned in the catalog, so the documented command cannot succeed for anyone |
|
||||
| Required headings | `## Install`, `## Non-goals`, `## Changelog` — per class. Present at the wrong depth is its own finding |
|
||||
| Required files | a file this class (or trait) needs is absent |
|
||||
| Repo references | an `open/<name>` in URL position resolves to nothing |
|
||||
| Relative links | a link points at a file that is not tracked |
|
||||
| Licence claim | the README cites a licence the repo has no file for |
|
||||
| Badges | a static badge asserts a test, build or coverage run that nothing verifies |
|
||||
| Badges | a static image badge — any host — asserts a test, build or coverage run that nothing verifies |
|
||||
| Boilerplate | template text nobody filled in |
|
||||
| Version consistency | manifest, README badge, newest CHANGELOG entry and the git tag disagree |
|
||||
| Description | empty, or past the length bound |
|
||||
|
|
@ -111,9 +113,8 @@ judgement. It lives in `register/repos.json`.
|
|||
| standalone | pip/uv | README, LICENSE |
|
||||
| org-profile | none | README |
|
||||
|
||||
A flat standard across every class would demand a CONTRIBUTING from a CSS
|
||||
library that accepts no contributions, and a roadmap from a five-line profile.
|
||||
That is how a gate teaches people to switch it off.
|
||||
A flat standard across every class would demand a roadmap from a five-line
|
||||
profile. That is how a gate teaches people to switch it off.
|
||||
|
||||
### Three outcomes on references, not two
|
||||
|
||||
|
|
@ -148,7 +149,7 @@ without that, a raw scan turns three dead names into about twenty.
|
|||
npm test
|
||||
```
|
||||
|
||||
67 tests over the pure classifiers. The reference fixtures are measured false
|
||||
77 tests over the pure classifiers. The reference fixtures are measured false
|
||||
positives, each with its expected verdict — the six that produced the
|
||||
three-outcome reference rule, plus the noise sources found by running the gate
|
||||
against a real repository: regexes inside code spans that are markdown links to
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue