Documentation
¶
Overview ¶
vettool bundles the repo's custom go/analysis analyzers for `go vet -vettool`. This lane is for TYPE-AWARE invariants only: the pattern-shaped rules (bespoke CSS, hard navigation, bespoke EventSource, inline style/script) already live in the contracts pipeline (framework/contracts, `gofastr verify`) with its exemption system — don't duplicate them here.
Two kinds of analyzer ship here. The gofastr* ones encode invariants this codebase learned the hard way, each traceable to fixes that had to be made more than once. The rest are stock x/tools passes that `go vet` does not enable by default; x/tools is already a direct dependency, so they cost no new module and satisfy the Go-team-only tooling rule.
Run via `make analyze`, the pre-commit hook, and CI's vet step:
go build -o dist/vettool ./cmd/vettool go vet -vettool=dist/vettool ./...