1
- version : " 2"
1
+ formatters :
2
+ enable :
3
+ - gofumpt
4
+ - goimports
5
+
6
+ settings :
7
+ goimports :
8
+ local-prefixes :
9
+ - github.com/argoproj/argo-cd/v3
10
+
2
11
issues :
3
12
max-issues-per-linter : 0
13
+
4
14
max-same-issues : 0
15
+
5
16
linters :
6
- exclusions :
7
- rules :
8
- - linters :
9
- - unparam
10
- path : (.+)_test\.go
11
- - path : (.+)\.go$
12
- text : SA5011
13
- paths :
14
- - third_party$
15
- - builtin$
16
- - examples$
17
- presets :
18
- - comments
19
- - common-false-positives
20
- - legacy
21
- - std-error-handling
22
17
enable :
23
18
- errorlint
24
19
- gocritic
@@ -27,12 +22,28 @@ linters:
27
22
- misspell
28
23
- perfsprint
29
24
- revive
25
+ - staticcheck
30
26
- testifylint
31
27
- thelper
32
28
- unparam
33
29
- usestdlibvars
34
30
- usetesting
35
31
- whitespace
32
+
33
+ exclusions :
34
+ rules :
35
+ - linters :
36
+ - unparam
37
+ path : (.+)_test\.go
38
+
39
+ presets :
40
+ - comments
41
+ - common-false-positives
42
+ - legacy
43
+ - std-error-handling
44
+
45
+ warn-unused : true
46
+
36
47
settings :
37
48
gocritic :
38
49
disabled-checks :
@@ -41,41 +52,55 @@ linters:
41
52
- exitAfterDefer
42
53
- mapKey
43
54
- typeSwitchVar
55
+
44
56
gomodguard :
45
57
blocked :
46
58
modules :
47
59
- github.com/golang-jwt/jwt/v4 :
48
60
recommendations :
49
61
- github.com/golang-jwt/jwt/v5
62
+
50
63
- github.com/imdario/mergo :
51
64
recommendations :
52
65
- dario.cat/mergo
53
66
reason : ' `github.com/imdario/mergo` has been renamed.'
67
+
54
68
- github.com/pkg/errors :
55
69
recommendations :
56
70
- errors
71
+
57
72
importas :
58
73
alias :
59
74
- pkg : github.com/golang-jwt/jwt/v5
60
75
alias : jwtgo
76
+
61
77
- pkg : k8s.io/api/apps/v1
62
78
alias : appsv1
79
+
63
80
- pkg : k8s.io/api/core/v1
64
81
alias : corev1
82
+
65
83
- pkg : k8s.io/api/rbac/v1
66
84
alias : rbacv1
85
+
67
86
- pkg : k8s.io/apimachinery/pkg/api/errors
68
87
alias : apierrors
88
+
69
89
- pkg : k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1
70
90
alias : apiextensionsv1
91
+
71
92
- pkg : k8s.io/apimachinery/pkg/apis/meta/v1
72
93
alias : metav1
94
+
73
95
- pkg : k8s.io/client-go/informers/core/v1
74
96
alias : informersv1
97
+
75
98
- pkg : errors
76
99
alias : stderrors
100
+
77
101
nolintlint :
78
102
require-specific : true
103
+
79
104
perfsprint :
80
105
# Optimizes even if it requires an int or uint type cast.
81
106
int-conversion : true
@@ -87,80 +112,115 @@ linters:
87
112
sprintf1 : true
88
113
# Optimizes into strings concatenation.
89
114
strconcat : true
115
+
90
116
revive :
91
117
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md
92
118
rules :
93
119
- name : bool-literal-in-expr
120
+
94
121
- name : blank-imports
95
122
disabled : true
123
+
96
124
- name : context-as-argument
97
125
arguments :
98
126
- allowTypesBefore : ' *testing.T,testing.TB'
127
+
99
128
- name : context-keys-type
100
129
disabled : true
130
+
101
131
- name : dot-imports
102
132
disabled : true
133
+
103
134
- name : duplicated-imports
135
+
104
136
- name : early-return
105
137
arguments :
106
138
- preserveScope
139
+
107
140
- name : empty-block
108
141
disabled : true
142
+
109
143
- name : error-naming
110
144
disabled : true
145
+
111
146
- name : error-return
147
+
112
148
- name : error-strings
113
149
disabled : true
150
+
114
151
- name : errorf
152
+
115
153
- name : identical-branches
154
+
116
155
- name : if-return
156
+
117
157
- name : increment-decrement
158
+
118
159
- name : indent-error-flow
119
160
arguments :
120
161
- preserveScope
162
+
121
163
- name : modifies-parameter
164
+
122
165
- name : optimize-operands-order
166
+
123
167
- name : range
168
+
124
169
- name : receiver-naming
170
+
125
171
- name : redefines-builtin-id
126
172
disabled : true
173
+
127
174
- name : redundant-import-alias
175
+
128
176
- name : superfluous-else
129
177
arguments :
130
178
- preserveScope
179
+
131
180
- name : time-equal
181
+
132
182
- name : time-naming
133
183
disabled : true
184
+
134
185
- name : unexported-return
135
186
disabled : true
187
+
136
188
- name : unnecessary-stmt
189
+
137
190
- name : unreachable-code
191
+
138
192
- name : unused-parameter
193
+
139
194
- name : use-any
195
+
140
196
- name : useless-break
197
+
141
198
- name : var-declaration
199
+
142
200
- name : var-naming
143
201
arguments :
144
202
- - ID
145
203
- - VM
146
204
- - skipPackageNameChecks : true
147
205
upperCaseConst : true
206
+
207
+ staticcheck :
208
+ checks :
209
+ - all
210
+ - -SA5011
211
+ - -ST1003
212
+ - -ST1016
213
+
148
214
testifylint :
149
215
enable-all : true
216
+
150
217
disable :
151
218
- go-require
219
+
152
220
usetesting :
153
221
os-mkdir-temp : false
154
- formatters :
155
- enable :
156
- - gofumpt
157
- - goimports
158
- settings :
159
- goimports :
160
- local-prefixes :
161
- - github.com/argoproj/argo-cd/v3
162
- exclusions :
163
- paths :
164
- - third_party$
165
- - builtin$
166
- - examples$
222
+
223
+ output :
224
+ show-stats : false
225
+
226
+ version : " 2"
0 commit comments