-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.golangci.yml
More file actions
153 lines (153 loc) · 2.92 KB
/
Copy path.golangci.yml
File metadata and controls
153 lines (153 loc) · 2.92 KB
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
version: "2"
output:
sort-order:
- linter
- file
linters:
default: none
enable:
- bodyclose
- cyclop
- durationcheck
- errcheck
- errorlint
- exhaustive
- funlen
- gocognit
- gocritic
- godot
- gosec
- govet
- ineffassign
- makezero
- misspell
- nilerr
- noctx
- nosprintfhostport
- predeclared
- revive
- rowserrcheck
- sqlclosecheck
- staticcheck
- testifylint
- thelper
- tparallel
- unconvert
- unused
- whitespace
settings:
cyclop:
max-complexity: 15
package-average: 0
errcheck:
check-type-assertions: true
check-blank: true
errorlint:
errorf: true
errorf-multi: true
asserts: true
comparison: true
exhaustive:
check:
- switch
default-signifies-exhaustive: true
funlen:
lines: 80
statements: 50
ignore-comments: true
gocognit:
min-complexity: 20
gocritic:
disabled-checks:
- whyNoLint
enabled-tags:
- diagnostic
- style
- performance
godot:
scope: declarations
capital: false
gosec:
excludes:
- G104
config:
G306: "0640"
govet:
disable:
- fieldalignment
enable-all: true
misspell:
locale: US
revive:
severity: warning
rules:
- name: exported
arguments:
- checkPrivateReceivers
- sayRepetitiveInsteadOfStutters
- name: var-naming
- name: package-comments
- name: indent-error-flow
- name: error-return
- name: error-strings
- name: error-naming
- name: dot-imports
- name: blank-imports
- name: context-as-argument
- name: context-keys-type
- name: time-naming
- name: unexported-return
- name: modifies-parameter
- name: superfluous-else
- name: unreachable-code
- name: waitgroup-by-value
- name: atomic
- name: range-val-address
- name: if-return
staticcheck:
checks:
- all
exclusions:
generated: lax
presets:
- comments
- common-false-positives
- legacy
- std-error-handling
rules:
- linters:
- cyclop
- errcheck
- funlen
- gocognit
- gosec
path: _test\.go
- linters:
- godot
path: cmd/
- linters:
- all
path: \.pb\.go$
- linters:
- all
path: mock_.*\.go$
- linters:
- cyclop
path: (.+)_test\.go
paths:
- vendor
- bin
- third_party$
- builtin$
- examples$
issues:
max-issues-per-linter: 50
max-same-issues: 5
fix: false
formatters:
exclusions:
generated: lax
paths:
- third_party$
- builtin$
- examples$