bunker/.golangci.yml
Stanislav N. aka pztrn 71c80799d2
Some checks failed
Linting and tests / Tests (push) Failing after 1m22s
Linting and tests / Linting (push) Failing after 1m32s
Linter configuration and linting.
2025-09-11 02:30:15 +05:00

94 lines
1.8 KiB
YAML

---
version: "2"
linters:
default: all
disable:
- containedctx
- depguard
- exhaustruct
- gochecknoglobals
- interfacebloat
- ireturn
- mnd
- testpackage
- tparallel
- unused
- varnamelen
- noinlineerr
- wsl
settings:
cyclop:
max-complexity: 30
package-average: 30
forbidigo:
forbid:
- pattern: ^(fmt\.Print(|f|ln)|print|println)$
- pattern: ^time\.Now\(\)($|\.F|\.A|\.B|\.L|\.UTC\(\)\.I|,|\))(# Calls of time\.Now() without \.UTC() is prohibited\.)?
funlen:
lines: 200
statements: 60
ignore-comments: true
gocyclo:
min-complexity: 20
govet:
enable-all: true
funcorder:
constructor: true
struct-method: false
alphabetical: true
lll:
line-length: 120
nestif:
min-complexity: 20
tagliatelle:
case:
rules:
json: snake
yaml: camel
use-field-name: true
wsl_v5:
allow-first-in-block: true
allow-whole-block: false
branch-max-lines: 2
exclusions:
generated: lax
rules:
- linters:
- gosec
path: .+_test\.go
- linters:
- godox
text: TODO
- linters:
- govet
text: declaration of "err" shadows
- path: (.+)\.go$
text: ST1000
- path: (.+)\.go$
text: package-comments
- linters:
- cyclop
path: (.+)_test\.go
paths:
- third_party$
- builtin$
- examples$
issues:
max-issues-per-linter: 0
max-same-issues: 0
formatters:
enable:
- gofmt
- gofumpt
settings:
gofumpt:
module-path: "bunker"
extra-rules: true
exclusions:
generated: lax
paths:
- third_party$
- builtin$
- examples$