build: update golangci-lint to v2.12.2 with canonical config
All checks were successful
check / check (push) Successful in 1m12s
All checks were successful
check / check (push) Successful in 1m12s
Replace the commit-pinned golangci-lint install refs in Dockerfile and script/bootstrap with the v2.12.2 version pin, and replace .golangci.yml with the canonical v2-schema config (lint settings now live under linters.settings, so the lll/funlen/cyclop/dupl thresholds are actually applied). Fix all findings surfaced by the newly-applied config: - goconst: introduce shared constants for repeated status, priority, and DNS fixture strings in watcher.go and the notify, state, and watcher tests - dupl: consolidate duplicated ntfy/slack HTTP-error tests and SendNotification endpoint-error tests behind shared helpers - lll: wrap long test table entries and comments; shorten one inline nolint justification
This commit is contained in:
@@ -4,14 +4,14 @@
|
||||
# installed tools are skipped. Base tooling comes from nix, apt, brew,
|
||||
# or apk (detected in that order); assumes nothing is present.
|
||||
# golangci-lint and goimports are installed via `go install` at the same
|
||||
# pinned commits the Dockerfile uses (never "latest").
|
||||
# pinned refs the Dockerfile uses (never "latest").
|
||||
set -eu
|
||||
|
||||
ROOT="$(cd "$(dirname "$0")/.." && pwd -P)"
|
||||
|
||||
# Pinned versions, 2026-07-07 (same pins as the Dockerfile)
|
||||
# golangci-lint v2.10.1
|
||||
GOLANGCI_LINT_REF="github.com/golangci/golangci-lint/v2/cmd/golangci-lint@5d1e709b7be35cb2025444e19de266b056b7b7ee"
|
||||
# Pinned versions, 2026-08-07 (same pins as the Dockerfile)
|
||||
# golangci-lint v2.12.2
|
||||
GOLANGCI_LINT_REF="github.com/golangci/golangci-lint/v2/cmd/golangci-lint@v2.12.2"
|
||||
# goimports v0.42.0
|
||||
GOIMPORTS_REF="golang.org/x/tools/cmd/goimports@009367f5c17a8d4c45a961a3a509277190a9a6f0"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user