mirror of
https://github.com/containerd/containerd.git
synced 2026-06-24 08:48:48 +00:00
golangci-lint: enable modernize linter
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@@ -1,11 +1,12 @@
|
|||||||
version: "2"
|
version: "2"
|
||||||
linters:
|
linters:
|
||||||
enable:
|
enable:
|
||||||
- copyloopvar # Checks for loop variable copies in Go 1.22+
|
- copyloopvar # Checks for loop variable copies in Go 1.22+
|
||||||
- depguard # Checks for dependencies that should not be (re)introduced. See "settings" for further details.
|
- depguard # Checks for dependencies that should not be (re)introduced. See "settings" for further details.
|
||||||
- dupword # Checks for duplicate words in the source code
|
- dupword # Checks for duplicate words in the source code
|
||||||
- gosec
|
- gosec
|
||||||
- misspell
|
- misspell
|
||||||
|
- modernize # Suggests modernizations to Go code; see https://pkg.go.dev/golang.org/x/tools/go/analysis/passes/modernize
|
||||||
- nolintlint
|
- nolintlint
|
||||||
- revive
|
- revive
|
||||||
- unconvert
|
- unconvert
|
||||||
@@ -40,6 +41,11 @@ linters:
|
|||||||
- G301
|
- G301
|
||||||
- G302
|
- G302
|
||||||
- G304
|
- G304
|
||||||
|
modernize:
|
||||||
|
disable:
|
||||||
|
# TODO(thaJeztah): enable testingcontext once github.com/AdamKorcz/go-118-fuzz-build is updated.
|
||||||
|
# see https://github.com/containerd/containerd/pull/13022#discussion_r2937038804
|
||||||
|
- testingcontext
|
||||||
staticcheck:
|
staticcheck:
|
||||||
checks:
|
checks:
|
||||||
- all
|
- all
|
||||||
|
|||||||
Reference in New Issue
Block a user