Anton Telyshev c65868c105
gocritic: support of enable-all and disable-all options (#4335)
Co-authored-by: Ludovic Fernandez <ldez@users.noreply.github.com>
2024-02-19 14:50:25 +01:00

21 lines
867 B
YAML

linters-settings:
gocritic:
disabled-checks:
- appendAssign
- switchTrue
enabled-checks:
- hugeParam
- ruleguard
settings:
hugeParam:
sizeThreshold: 24
ruleguard:
failOn: dsl,import
# Comma-separated paths to ruleguard files.
# The ${configDir} is substituted by the directory containing the golangci-lint config file.
# Note about the directory structure for functional tests:
# The ruleguard files used in functional tests cannot be under the 'testdata' directory.
# This is because they import the 'github.com/quasilyte/go-ruleguard/dsl' package,
# which needs to be added to go.mod. The testdata directory is ignored by go mod.
rules: '${configDir}/../../ruleguard/preferWriteString.go,${configDir}/../../ruleguard/stringsSimplify.go'