Migrate to golangci-lint 2

This commit is contained in:
Sandro Jäckel 2025-09-09 18:31:49 +02:00 committed by Jörg Thalheim
parent 6be7eb746c
commit 74f0a60d61

View file

@ -1,12 +1,55 @@
version: "2"
linters:
enable:
- asasalint
- asciicheck
- bidichk
- bodyclose
- contextcheck
- durationcheck
- errchkjson
- errorlint
- exhaustive
- gocheckcompilerdirectives
- gochecksumtype
- gosec
- gosmopolitan
- loggercheck
- makezero
- misspell
- musttag
- nilerr
- nilnesserr
- protogetter
- reassign
- recvcheck
- revive
- rowserrcheck
- spancheck
- sqlclosecheck
- staticcheck
- testifylint
- unparam
- zerologlint
disable:
- noctx
exclusions:
generated: lax
presets:
- bugs
- unused
- comments
- common-false-positives
- legacy
- std-error-handling
paths:
- third_party$
- builtin$
- examples$
formatters:
enable:
- gofmt
- misspell
- revive
- stylecheck
disable:
# direnv is not a web server, context is not strictly necessary.
- noctx
exclusions:
generated: lax
paths:
- third_party$
- builtin$
- examples$