# Lint registry for scripts/lint.py — the extension point.
# Add a lint: append a [[lint]] block. No code changes needed.
# name — shown in the summary table.
# globs — files this lint applies to. A lint whose file type didn't
# command — {skill} expands to this skill's directory; {files} to the
# matched files. If the first token isn't an installed tool,
# the lint is skipped with a warning, never failed.
# required — true: a non-zero exit fails the run. false: advisory.
# note — one line of context, echoed when the lint runs.
command = "{skill}/scripts/lint_go.sh"
note = "go vet/-race/golangci-lint (degrade to warning if missing) + house rules: function size, %w wrapping, no naked go func(), domain/service coverage floor — a compile/vet/fmt-class failure is a build break"
globs = ["**/openapi.yaml", "**/openapi.yml", "**/*.openapi.yaml", "**/*.openapi.yml"]
command = "{skill}/scripts/lint_openapi.sh {files}"
note = "Spectral (degrades to a PyYAML/grep structural check if missing) + house rules: RFC 9457 Problem Details shape, cursor pagination, Idempotency-Key on POST"
# ---------------------------------------------------------------------------
# Add this when redocly is installed (not present on this machine — Wave 3
# upgrade per docs/improvement-plan-2026-07-09.md Finding 3). `redocly lint`
# replaces the text-proximity RFC 9457 check above with a real OpenAPI/JSON
# Schema parse. Until then the house-rule check in lint_openapi.sh is the
# active enforcement — see references/openapi.md "Redocly upgrade path".
# globs = ["**/openapi.yaml", "**/openapi.yml", "**/*.openapi.yaml", "**/*.openapi.yml"]
# command = "redocly lint {files}"
# note = "real OpenAPI parse/validate; advisory until it replaces the house-rule proximity check as required"
# ---------------------------------------------------------------------------
# verify_scaffold.sh is intentionally NOT registered here. It is a one-shot
# scaffold verifier invoked once after generating a new service (build,
# layout, Helm/Dockerfile/CI presence, tests pass) — not a file-change lint.
# Running it on every changed .go file would be wrong: it always inspects
# the whole repo, not the matched files, and most of its checks (Helm chart
# present, CI workflow present) have no "file changed" trigger at all.
# It stays a separate SKILL.md entrypoint: `scripts/verify_scaffold.sh [repo-dir]`.