forked from flashbots/mev-boost-relay
-
Notifications
You must be signed in to change notification settings - Fork 2
/
.golangci.yaml
116 lines (103 loc) · 2.14 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
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
# https://golangci-lint.run/usage/linters
linters:
enable-all: true
disable:
- cyclop
- forbidigo
- funlen
- gochecknoglobals
- gochecknoinits
- gocritic
- godot
- godox
- gomnd
- lll
- musttag
- nestif
- nilnil
- nlreturn
- noctx
- nonamedreturns
- nosnakecase
- paralleltest
- revive
- testpackage
- unparam
- varnamelen
- wrapcheck
- wsl
- deadcode
- varcheck
- interfacebloat
#
# Disabled because of generics:
#
- contextcheck
- rowserrcheck
- sqlclosecheck
- structcheck
- wastedassign
#
# Disabled because deprecated:
#
- exhaustivestruct
- golint
- ifshort
- interfacer
- maligned
- scopelint
linters-settings:
#
# The G108 rule throws a false positive. We're not actually vulnerable. If
# you're not careful the profiling endpoint is automatically exposed on
# /debug/pprof if you import net/http/pprof. See this link:
#
# https://mmcloughlin.com/posts/your-pprof-is-showing
#
gosec:
excludes:
- G108
gocognit:
min-complexity: 85 # default: 30
gocyclo:
min-complexity: 70 # default: 30
gomoddirectives:
replace-allow-list:
- github.com/attestantio/go-eth2-client
maintidx:
under: 5
tagliatelle:
case:
rules:
json: snake
gofumpt:
extra-rules: true
exhaustruct:
exclude:
#
# Because it's easier to read without the other fields.
#
- 'GetPayloadsFilters'
#
# Structures outside our control that have a ton of settings. It doesn't
# make sense to specify all of the fields.
#
- 'cobra.Command'
- 'database.*Entry'
- 'http.Server'
- 'logrus.*Formatter'
- 'Options' # redis
#
# Excluded because there are private fields (not capitalized) that are
# not initialized. If possible, I think these should be altered.
#
- 'Datastore'
- 'Housekeeper'
- 'MockBeaconClient'
- 'RelayAPI'
- 'Webserver'
issues:
exclude-rules:
- path: (.+)_test.go
linters:
- exhaustruct