-
-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy path.golangci.yaml
76 lines (71 loc) · 1.91 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
76
version: "2"
run:
go: "1.24"
timeout: 10m
tests: false
allow-parallel-runners: true
issues-exit-code: 2
linters:
default: all
disable:
- bodyclose
- containedctx # Struct should not contain context, action does.
- contextcheck
- cyclop # Complex functions are not good.
- depguard
- dogsled
- dupl # Check code duplications.
- exhaustive # Doesn't really make sense.
- exhaustruct # Doesn't really make sense.
- forcetypeassert # Priority: that can lead to serious crashes.
- funlen # Break long functions.
- gochecknoglobals
- gochecknoinits # Init functions cause an import to have side effects,
- err113
- interfacebloat
- ireturn # Accept interface, return concrate.
- lll
- loggercheck # Doesn't really make sense.
- nestif # Some nexted if statements are 8 or 9 deep.
- nilnil # A function should return either something valuable
- nonamedreturns # Either named return, or use simply `return`.
- paralleltest
- rowserrcheck
- sqlclosecheck
- tagliatelle
- testpackage # Blackbox testing is preffered.
- unparam
- varnamelen # m, d, p < These are not so meaningful variables.
- wastedassign
- wrapcheck
- wsl
settings:
funlen:
lines: 110
statements: 60
cyclop:
max-complexity: 60
gocognit:
min-complexity: 60
nolintlint:
allow-unused: false
require-explanation: true
require-specific: false
varnamelen:
ignore-names:
- err
- wg
- id
revive:
rules:
- name: package-comments
disabled: true
- name: exported
disabled: true
lll:
line-length: 120
exclusions:
paths:
- v1beta1/types_jsonschema.go
- v1beta1/marshal.go
- v1beta1/marshal_test.go