You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Check for pass []any as any in variadic func(...any).
15
+
# [fast: false, auto-fix: false]
16
+
- asasalint
17
+
15
18
# Check that code does not contain non-ASCII identifiers.
16
19
# [fast: true, auto-fix: false]
17
20
- asciicheck
18
21
22
+
# Checks for dangerous unicode character sequences.
23
+
# [fast: true]
24
+
- bidichk
25
+
19
26
# Check whether HTTP response body is closed successfully.
20
27
# [fast: false, auto-fix: false]
21
28
- bodyclose
@@ -32,6 +39,10 @@ linters:
32
39
# [fast: false, auto-fix: false]
33
40
- errcheck
34
41
42
+
# Checks types passed to the json encoding functions. Reports unsupported types and reports occurrences where the check for the returned error can be omitted.
43
+
# [fast: false, autofix: false]
44
+
- errchkjson
45
+
35
46
# Check that sentinel errors are prefixed with the `Err` and error types are suffixed with the `Error`.
36
47
# [fast: false, auto-fix: false]
37
48
- errname
@@ -44,9 +55,9 @@ linters:
44
55
# [fast: ?, auto-fix: true]
45
56
- exptostd
46
57
47
-
# Check package import order and make it always deterministic.
48
-
# [fast: true, auto-fix: true]
49
-
- gci
58
+
# Check that no global variables exist.
59
+
# [fast: false, auto-fix: false]
60
+
- gochecknoglobals
50
61
51
62
# Check that no init functions are present in Go code.
52
63
# [fast: true, auto-fix: false]
@@ -60,10 +71,6 @@ linters:
60
71
# [fast: true, auto-fix: true]
61
72
- godot
62
73
63
-
# Check whether code was gofumpt-ed.
64
-
# [fast: true, auto-fix: true]
65
-
- gofumpt
66
-
67
74
# Manage the use of 'replace', 'retract', and 'excludes' directives in go.mod.
68
75
# [fast: true, auto-fix: false]
69
76
- gomoddirectives
@@ -76,9 +83,9 @@ linters:
76
83
# [fast: true, auto-fix: false]
77
84
- goprintffuncname
78
85
79
-
#Check for code that can be simplified.
86
+
#Inspects source code for security problems.
80
87
# [fast: false, auto-fix: false]
81
-
- gosimple
88
+
- gosec
82
89
83
90
# Report suspicious constructs, such as Printf calls whose arguments do not align with the format string.
84
91
# [fast: false, auto-fix: false]
@@ -108,6 +115,10 @@ linters:
108
115
# [fast: false, auto-fix: false]
109
116
- nilerr
110
117
118
+
# Finds sending http request without context.Context.
119
+
# [fast: false, auto-fix: false]
120
+
- noctx
121
+
111
122
# Report ill-formed or insufficient nolint directives.
112
123
# [fast: true, auto-fix: false]
113
124
- nolintlint
@@ -128,10 +139,22 @@ linters:
128
139
# [fast: false, auto-fix: true]
129
140
- protogetter
130
141
142
+
# Fast, configurable, extensible, flexible, and beautiful linter for Go. Drop-in replacement of golint.
143
+
# [fast: false, auto-fix: true]
144
+
- revive
145
+
131
146
# Check whether Err of rows is checked successfully.
132
147
# [fast: false, auto-fix: false]
133
148
- rowserrcheck
134
149
150
+
# Ensure consistent code style when using log/slog.
151
+
# [fast: false, auto-fix: false]
152
+
- sloglint
153
+
154
+
# Checks for mistakes with OpenTelemetry/Census spans.
155
+
# [fast: false, auto-fix: false]
156
+
- spancheck
157
+
135
158
# Check that sql.Rows and sql.Stmt are closed.
136
159
# [fast: false, auto-fix: false]
137
160
- sqlclosecheck
@@ -140,18 +163,10 @@ linters:
140
163
# [fast: false, auto-fix: false]
141
164
- staticcheck
142
165
143
-
# A replacement for golint.
144
-
# [fast: false, auto-fix: false]
145
-
- stylecheck
146
-
147
166
# Detect inappropriate usage of t.Parallel() method in your Go test codes.
148
167
# [fast: false, auto-fix: false]
149
168
- tparallel
150
169
151
-
# Parses and type-checks Go code.
152
-
# [fast: false, auto-fix: false]
153
-
- typecheck
154
-
155
170
# Remove unnecessary type conversions.
156
171
# [fast: false, auto-fix: false]
157
172
- unconvert
@@ -160,120 +175,91 @@ linters:
160
175
# [fast: false, auto-fix: false]
161
176
- unused
162
177
178
+
# A linter that detect the possibility to use variables/constants from the Go standard library.
179
+
# [fast: true, auto-fix: true]
180
+
- usestdlibvars
181
+
163
182
# Find wasted assignment statements.
164
183
# [fast: false, auto-fix: false]
165
184
- wastedassign
166
185
167
186
# Detect leading and trailing whitespace.
168
187
# [fast: true, auto-fix: true]
169
188
- whitespace
170
-
171
-
# Check that no global variables exist.
172
-
# [fast: true, auto-fix: false]
173
-
- gochecknoglobals
174
-
175
-
# Inspect source code for security problems.
176
-
# [fast: false, auto-fix: false]
177
-
- gosec
178
-
179
-
# Find sending http request without context.Context.
180
-
# [fast: false, auto-fix: false]
181
-
- noctx
182
-
183
-
# Drop-in replacement of golint.
184
-
# [fast: false, auto-fix: false]
185
-
- revive
186
-
187
-
# Check for pass []any as any in variadic func(...any).
188
-
# [fast: false, auto-fix: false]
189
-
- asasalint
190
-
191
-
# Check for dangerous unicode character sequences.
192
-
# [fast: true, auto-fix: false]
193
-
- bidichk
194
-
195
-
# Check types passed to the json encoding functions.
196
-
# [fast: false, auto-fix: false]
197
-
- errchkjson
198
-
199
-
# Check for the possibility to use variables/constants from the Go standard library.
200
-
# [fast: true, auto-fix: false]
201
-
- usestdlibvars
202
-
203
-
# Checks for mistakes with OpenTelemetry/Census spans.
204
-
# [fast: false, auto-fix: false]
205
-
- spancheck
206
-
207
-
# Ensure consistent code style when using log/slog.
208
-
- sloglint
209
-
linters-settings:
210
-
gomodguard:
211
-
blocked:
212
-
modules:
213
-
- github.com/sirupsen/logrus:
214
-
recommendations:
215
-
- go.uber.org/zap
216
-
reason: "Use Zap for logging."
217
-
- github.com/rs/zerolog:
218
-
recommendations:
219
-
- go.uber.org/zap
220
-
reason: "Use Zap for logging."
221
-
- github.com/pkg/errors:
222
-
recommendations:
223
-
- errors
224
-
- fmt
225
-
reason: "Use the standard library error packages."
226
-
- golang.org/x/xerrors:
227
-
recommendations:
228
-
- errors
229
-
- fmt
230
-
reason: "Use the standard library error packages."
0 commit comments