[ci] Tighten shellcheck severity + add plugin schema validation#107
Merged
Conversation
Catches SC2086 (unquoted variable) and SC2155 (declare-and-assign) in release-critical scripts; renames step to signal intent.
Pins claude-code-plugin-manifest and claude-code-marketplace schemas locally under .claude-plugin/schemas/ so CI can validate against them without network calls; $comment records provenance + fetch date.
Installs jsonschema==4.23.0 and validates plugin.json + marketplace.json against vendored schemas; fails fast before tag-version check so broken manifests never reach the GitHub Release step.
Points to canonical SchemaStore URLs for IDE autocomplete/validation; the CI gate enforces the vendored copy so no live network call at runtime.
Vendored schemas declare draft-07; using Draft202012Validator silently skips 'definitions' sub-schemas. Draft7Validator applies the correct evaluation semantics.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
severityfromerror→warning; catches SC2086 (unquoted vars) and SC2155 (declare-and-assign masking) in all*.shscripts and githooks. Rename step for clarity.plugin.schema.jsonandmarketplace.schema.jsonfrom SchemaStore under.claude-plugin/schemas/(provenance in$comment). Add a Python/jsonschema==4.23.0validation step torelease.yml— runs afterjq empty, before tag-version check, so a broken manifest fails fast. Add$schemaIDE-hint field to both manifests.Test Plan
shellcheck --severity=warning scripts/*.sh .githooks/commit-msg .githooks/pre-commit .githooks/pre-push→ exit 0 locallyDraft7Validatoragainst real manifests) → both passdel(.name)from plugin.json) → exit 1 +'name' is a required property$schemafields present in both manifests and do not cause schema violationsclaude /plugins) — confirm no loader warnings after$schemaaddedshellcheckjob green on this PRvalidate-plugin-filesjob green on this PRCloses #74, Closes #77