Debian Codegraph @

.golangci.yml

raw symbols SCIP
1 # Copyright 2023 The Authors (see AUTHORS file)
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 # http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 run:
16 # default: '1m'
17 timeout: '5m'
18
19 # default: []
20 build-tags:
21 - 'all'
22
23 # default: []
24 exclude-dirs:
25 - 'third_party'
26
27 # default: true
28 skip-dirs-use-default: false
29
30 # default: ''
31 modules-download-mode: 'readonly'
32
33 # default: false
34 allow-parallel-runners: true
35
36 linters:
37 enable:
38 - 'asasalint'
39 - 'asciicheck'
40 - 'bidichk'
41 - 'bodyclose'
42 - 'containedctx'
43 - 'dupword'
44 - 'durationcheck'
45 - 'errcheck'
46 - 'errchkjson'
47 - 'errname'
48 - 'errorlint'
49 - 'execinquery'
50 - 'exhaustive'
51 - 'exportloopref'
52 - 'forcetypeassert'
53 - 'gci'
54 - 'gocheckcompilerdirectives'
55 - 'godot'
56 - 'gofmt'
57 - 'gofumpt'
58 - 'goheader'
59 - 'goimports'
60 - 'goprintffuncname'
61 - 'gosec'
62 - 'gosimple'
63 - 'govet'
64 - 'importas'
65 - 'ineffassign'
66 - 'loggercheck'
67 - 'makezero'
68 - 'mirror'
69 - 'misspell'
70 - 'nilerr'
71 - 'noctx'
72 - 'nolintlint'
73 - 'nosprintfhostport'
74 - 'paralleltest'
75 - 'prealloc'
76 - 'predeclared'
77 - 'protogetter'
78 - 'rowserrcheck'
79 - 'sloglint'
80 - 'spancheck'
81 - 'sqlclosecheck'
82 - 'staticcheck'
83 - 'stylecheck'
84 - 'tenv'
85 - 'thelper'
86 - 'typecheck'
87 - 'unconvert'
88 - 'unused'
89 - 'wastedassign'
90 - 'whitespace'
91 - 'wrapcheck'
92
93 issues:
94 # default: []
95 exclude:
96 - '^G102:' # gosec: we have to bind to all ifaces in Cloud Run services
97
98 # default: []
99 exclude-rules:
100 # Exclude test files from certain linters
101 - path: '_test.go'
102 linters:
103 - 'wrapcheck'
104
105 # default: 50
106 max-issues-per-linter: 0
107
108 # default: 3
109 max-same-issues: 0
110
111 gci:
112 sections:
113 - 'standard'
114 - 'default'
115 - 'blank'
116 - 'dot'
117
118 skip-generated: true
119 custom-order: true
120
121 gofumpt:
122 # default: false
123 extra-rules: true
124
125 sloglint:
126 # default: false
127 context-only: true
128 # default: false
129 static-msg: false
130 # default: '' (snake, kebab, camel, pascal)
131 key-naming-case: 'snake'
132 # default: false
133 args-on-sep-lines: true
134
135 severity:
136 # default: ''
137 default-severity: 'error'