mirror of
https://github.com/lightninglabs/aperture.git
synced 2025-12-17 09:04:19 +01:00
linter: migrate .golangci.yml to v2
The migration was done via: golangci-lint migrate --skip-validation
This commit is contained in:
@@ -1,16 +1,8 @@
|
|||||||
|
version: "2"
|
||||||
run:
|
run:
|
||||||
# timeout for analysis
|
|
||||||
timeout: 4m
|
|
||||||
|
|
||||||
# Linting uses a lot of memory. Keep it under control by only running a single
|
# Linting uses a lot of memory. Keep it under control by only running a single
|
||||||
# worker.
|
# worker.
|
||||||
concurrency: 1
|
concurrency: 1
|
||||||
|
|
||||||
linters-settings:
|
|
||||||
gofmt:
|
|
||||||
# simplify code: gofmt with `-s` option, true by default
|
|
||||||
simplify: true
|
|
||||||
|
|
||||||
linters:
|
linters:
|
||||||
|
|
||||||
# Specify an enabled list of linters rather than a disabled list because
|
# Specify an enabled list of linters rather than a disabled list because
|
||||||
@@ -19,27 +11,41 @@ linters:
|
|||||||
- bodyclose
|
- bodyclose
|
||||||
- copyloopvar
|
- copyloopvar
|
||||||
- dupl
|
- dupl
|
||||||
- errcheck
|
|
||||||
- goconst
|
- goconst
|
||||||
- gocritic
|
- gocritic
|
||||||
- gocyclo
|
- gocyclo
|
||||||
- gofmt
|
|
||||||
- goimports
|
|
||||||
- gosimple
|
|
||||||
- govet
|
|
||||||
- ineffassign
|
|
||||||
- misspell
|
- misspell
|
||||||
- nakedret
|
- nakedret
|
||||||
- prealloc
|
- prealloc
|
||||||
- staticcheck
|
- staticcheck
|
||||||
- stylecheck
|
|
||||||
- typecheck
|
|
||||||
- unconvert
|
- unconvert
|
||||||
- unparam
|
- unparam
|
||||||
- unused
|
exclusions:
|
||||||
|
generated: lax
|
||||||
issues:
|
presets:
|
||||||
exclude-rules:
|
- comments
|
||||||
- path: internal/test
|
- common-false-positives
|
||||||
linters:
|
- legacy
|
||||||
|
- std-error-handling
|
||||||
|
rules:
|
||||||
|
- linters:
|
||||||
- goconst
|
- goconst
|
||||||
|
path: internal/test
|
||||||
|
paths:
|
||||||
|
- third_party$
|
||||||
|
- builtin$
|
||||||
|
- examples$
|
||||||
|
formatters:
|
||||||
|
enable:
|
||||||
|
- gofmt
|
||||||
|
- goimports
|
||||||
|
settings:
|
||||||
|
gofmt:
|
||||||
|
# simplify code: gofmt with `-s` option, true by default
|
||||||
|
simplify: true
|
||||||
|
exclusions:
|
||||||
|
generated: lax
|
||||||
|
paths:
|
||||||
|
- third_party$
|
||||||
|
- builtin$
|
||||||
|
- examples$
|
||||||
|
|||||||
Reference in New Issue
Block a user