-
Notifications
You must be signed in to change notification settings - Fork 16
/
.golangci.yaml
76 lines (73 loc) · 1.71 KB
/
.golangci.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
run:
concurrency: 8
deadline: 3m
issues-exit-code: 1
tests: true
output:
formats: colored-line-number
print-issued-lines: true
print-linter-name: true
issues:
exclude:
- 'ST1000: at least one file in a package should have a package comment'
- 'package-comments: should have a package comment'
exclude-dirs:
- vendor
exclude-dirs-use-default: false
exclude-files:
- test/cne/test_suite_test.go
exclude-use-default: false
linters-settings:
govet:
# Enable all analyzers.
# Default: false
enable-all: true
# Disable analyzers by name.
# Run `go tool vet help` to see all analyzers.
# Default: []
disable:
- fieldalignment # too strict
# Settings per analyzer.
settings:
shadow:
# Whether to be strict about shadowing; can be noisy.
# Default: false
strict: true
gocyclo:
# minimal code complexity to report, 30 by default (but we recommend 10-20)
min-complexity: 50
goconst:
min-len: 3
min-occurrences: 4
decorder:
# Required order of `type`, `const`, `var` and `func` declarations inside a file.
# Default: types before constants before variables before functions.
dec-order:
- type
- const
- var
- func
linters:
disable-all: true
enable: # NOTE: please keep this list alphabetically sorted
- bodyclose
- decorder
- dogsled
#- errcheck
- goconst
- gocyclo
- goimports
#- gosec
- gosimple
- govet
- ineffassign
- misspell
- revive
- stylecheck
- staticcheck # is a go vet on steroids, applying a ton of static analysis checks
- typecheck
- unconvert
- unparam
- unused
- whitespace
fast: false