use golangci-lint migrate to eliminate error (#3220)

fixes #3219

Signed-off-by: Raymond Augé <raymond.auge@liferay.com>
This commit is contained in:
Raymond Augé
2025-05-17 13:42:45 +05:30
committed by GitHub
parent 9e275e7ced
commit 313ceef1ed
+27 -27
View File
@@ -1,36 +1,36 @@
version: "2"
linters: linters:
enable: enable:
# Default linter
- errcheck
- gosimple
- govet
- ineffassign
- staticcheck
- typecheck
- unused
# Additional linters
- gofmt
- goimports
- misspell - misspell
- nakedret - nakedret
- unconvert
- promlinter - promlinter
# Enable in future - unconvert
# - bodyclose settings:
# - dogsled
# - dupl
# - gosec
# - nilerr
# - prealloc
# - revive
# - unparam
# - wrapcheck
# - gocritic
linters-settings:
errcheck: errcheck:
exclude-functions: exclude-functions:
- (*go.uber.org/zap.Logger).Sync - (*go.uber.org/zap.Logger).Sync
exclusions:
generated: lax
presets:
- comments
- common-false-positives
- legacy
- std-error-handling
paths:
- third_party$
- builtin$
- examples$
formatters:
enable:
- gofmt
- goimports
settings:
goimports: goimports:
# put imports beginning with prefix after 3rd-party packages; local-prefixes:
# it's a comma-separated list of prefixes - github.com/fission/fission
local-prefixes: github.com/fission/fission exclusions:
generated: lax
paths:
- third_party$
- builtin$
- examples$