mirror of
https://github.com/agent-substrate/substrate.git
synced 2026-11-10 10:13:50 +08:00
Adds golangci-lint v2.12.2 using the per-tool-module pattern under hack/tools/golangci-lint/. The verifier at hack/verify/golangci-lint.sh is auto-discovered by hack/verify-all.sh, so the existing CI verify step picks it up with no workflow YAML change. Ships .golangci.yaml with the standard linter set, a make lint target, and a verify wrapper that pins GOOS=linux so ateom-gvisor's netlink references typecheck on macOS the same way they do on CI. Adjustments to keep the first run clean: two dead-code deletions ((*runsc).cmdList, MemoryPullCache.gcsClient), two SA9003 empty branches replaced with slog.Error / t.Logf, one S1008 return-bool simplification, and inline //nolint for one intentional best-effort ReleaseLock plus four audit-tracked SA1019 deprecations. Signed-off-by: Davanum Srinivas <davanum@gmail.com>