nurse/.golangci.yml

133 lines
2.3 KiB
YAML
Raw Permalink Normal View History

2022-04-28 16:35:02 +00:00
linters-settings:
dupl:
threshold: 100
funlen:
lines: 100
statements: 50
gci:
2024-04-10 06:35:15 +00:00
sections:
- standard
- default
- prefix(code.icb4dc0.de/prskr/nurse)
- blank
- dot
- alias
custom-order: true
2022-04-28 16:35:02 +00:00
goconst:
min-len: 2
min-occurrences: 2
gocritic:
enabled-tags:
- diagnostic
- opinionated
- performance
disabled-checks:
- ifElseChain
- octalLiteral
- wrapperFunc
# see https://github.com/golangci/golangci-lint/issues/2649
- hugeParam
- rangeValCopy
# settings:
# hugeParam:
# sizeThreshold: 200
gocyclo:
min-complexity: 15
goimports:
local-prefixes: code.1533b4dc0.de/prskr/nurse
2022-04-28 16:35:02 +00:00
golint:
min-confidence: 0
gomnd:
2024-04-10 06:35:15 +00:00
checks:
- argument
- case
- condition
- return
2022-04-28 16:35:02 +00:00
gomoddirectives:
replace-allow-list:
- github.com/docker/docker
2022-04-28 16:35:02 +00:00
govet:
enable-all: true
disable:
- fieldalignment
# see https://github.com/golangci/golangci-lint/issues/2649
- nilness
- unusedwrite
importas:
no-unaliased: true
lll:
line-length: 140
misspell:
locale: US
2022-04-28 16:35:02 +00:00
linters:
disable-all: true
enable:
- contextcheck
- dogsled
- dupl
- errcheck
- errchkjson
- errname
- errorlint
- exhaustive
- exportloopref
- funlen
- gocognit
- goconst
2022-09-27 20:19:27 +00:00
# - gocritic
2022-04-28 16:35:02 +00:00
- gocyclo
- godox
- gofumpt
- goimports
- gomoddirectives
- gomnd
- gosec
2022-09-27 20:19:27 +00:00
- gosimple
2022-04-28 16:35:02 +00:00
- govet
- importas
- ineffassign
2022-09-27 20:19:27 +00:00
# - ireturn - enable later
2022-04-28 16:35:02 +00:00
- lll
- misspell
- nakedret
- nestif
- nilnil
- noctx
2022-09-22 09:46:36 +00:00
- nolintlint
2022-04-28 16:35:02 +00:00
- paralleltest
- prealloc
- predeclared
- promlinter
2022-09-27 20:19:27 +00:00
- staticcheck
- stylecheck
2022-04-28 16:35:02 +00:00
- testpackage
- thelper
2022-09-27 20:19:27 +00:00
# - typecheck
2022-04-28 16:35:02 +00:00
- unconvert
- unparam
- whitespace
2022-09-22 09:46:36 +00:00
- unused
2022-04-28 16:35:02 +00:00
- wastedassign
issues:
# Excluding configuration per-path, per-linter, per-text and per-source
exclude-rules:
- path: _test\.go
linters:
- dupl
- funlen
- gocognit
- gomnd
- govet
2022-09-27 20:19:27 +00:00
- path: magefiles/.*\.go
linters:
- typecheck
- unused
- govet
2022-04-28 16:35:02 +00:00
run:
modules-download-mode: readonly
timeout: 5m