From c9f8758570a00a41092c7e5cbbb19bcc30707393 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Sat, 8 Feb 2025 18:29:42 +0100 Subject: [PATCH] golangci-lint: enable reassign linter Detects reassigning a top-level variable in another package. https://github.com/curioswitch/go-reassign Signed-off-by: Sebastiaan van Stijn --- .golangci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.golangci.yml b/.golangci.yml index 8ba7c54a2c..93c71a7ae4 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -24,6 +24,7 @@ linters: - misspell # Detects commonly misspelled English words in comments. - nilnesserr # Detects returning nil errors. It combines the features of nilness and nilerr, - nosprintfhostport # Detects misuse of Sprintf to construct a host with port in a URL. + - reassign # Detects reassigning a top-level variable in another package. - revive # Metalinter; drop-in replacement for golint. - spancheck # Detects mistakes with OpenTelemetry/Census spans. - staticcheck