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
Copy file name to clipboardExpand all lines: .golangci.yml
+6-13Lines changed: 6 additions & 13 deletions
Original file line number
Diff line number
Diff line change
@@ -1,15 +1,8 @@
1
1
linters-settings:
2
2
govet:
3
-
# check-shadowing: true
4
-
check-shadowing: false
5
-
exhaustive:
6
-
default-signifies-exhaustive: true
7
-
gomodguard:
8
-
blocked:
9
-
modules:
10
-
- github.com/pkg/errors:
11
-
recommendations:
12
-
- errors
3
+
check-shadowing: true
4
+
gocyclo:
5
+
min-complexity: 15
13
6
14
7
linters:
15
8
enable:
@@ -22,7 +15,7 @@ linters:
22
15
- depguard # Go linter that checks if package imports are in a list of acceptable packages
23
16
# - dogsled # Checks assignments with too many blank identifiers (e.g. x, _, _, _, := f())
24
17
# - dupl # Tool for code clone detection
25
-
#- durationcheck # check for two durations multiplied together
18
+
- durationcheck # check for two durations multiplied together
26
19
- errcheck # Errcheck is a program for checking for unchecked errors in go programs. These unchecked errors can be critical bugs in some cases
27
20
- errchkjson # Checks types passed to the json encoding functions. Reports unsupported types and optionally reports occations, where the check for the returned error can be omitted.
28
21
# - errname # Checks that sentinel errors are prefixed with the `Err` and error types are suffixed with the `Error`.
@@ -31,7 +24,7 @@ linters:
31
24
- exportloopref # checks for pointers to enclosing loop variables
32
25
# - forbidigo # Forbids identifiers
33
26
# - forcetypeassert # finds forced type assertions
34
-
#- gci # Gci control golang package import order and make it always deterministic.
27
+
- gci # Gci control golang package import order and make it always deterministic.
35
28
# - gochecknoglobals # Checks that no globals are present in Go code
36
29
# - gochecknoinits # Checks that no init functions are present in Go code
37
30
# - gocognit # Computes and checks the cognitive complexity of functions
@@ -69,7 +62,7 @@ linters:
69
62
- typecheck # Like the front-end of a Go compiler, parses and type-checks Go code
70
63
- unconvert # Remove unnecessary type conversions
71
64
# - unparam # Reports unused function parameters
72
-
#- unused # Checks Go code for unused constants, variables, functions and types
65
+
- unused # Checks Go code for unused constants, variables, functions and types
73
66
- varcheck # Finds unused global variables and constants
0 commit comments