Debian Codegraph @

.golangci.yml

raw symbols SCIP
1 # Options for analysis running.
2 run:
3 # The default concurrency value is the number of available CPU.
4 concurrency: 4
5
6 # Timeout for analysis, e.g. 30s, 5m.
7 # Default: 1m
8 timeout: 1m
9
10 # Include test files or not.
11 # Default: true
12 tests: false
13
14 # Which files to skip: they will be analyzed, but issues from them won't be reported.
15 # Default value is empty list, but there is no need to include all autogenerated files,
16 # we confidently recognize autogenerated files.
17
18 #skip-files:
19 # - ".*\\.my\\.go$"
20 # - lib/bad.go
21
22 # Allowed values: readonly|vendor|mod
23 # By default, it isn't set.
24 modules-download-mode: readonly
25
26 # Allow multiple parallel golangci-lint instances running.
27 # If false (default) - golangci-lint acquires file lock on start.
28 allow-parallel-runners: false
29
30 linters:
31 # Run only fast linters from enabled linters set (first run won't be fast)
32 # Default: false
33 # fast: true
34
35 # Disable all linters.
36 disable-all: true
37
38 # Enable specific linter
39 # https://golangci-lint.run/usage/linters/#enabled-by-default
40 enable:
41 - bodyclose
42 - containedctx
43 # - deadcode
44 - depguard
45 - dogsled
46 - dupl
47 - dupword
48 - durationcheck
49 - errcheck
50 - errchkjson
51 - errname
52 - errorlint
53 - execinquery
54 - exhaustive
55 - exportloopref
56 - gochecknoinits
57 - gocritic
58 - godot
59 # - godox
60 - gofmt
61 # - gofumpt
62 - goimports
63 # - golint
64 # - gomnd
65 - gomoddirectives
66 - gomodguard
67 - goprintffuncname
68 - gosec
69 - gosimple
70 - govet
71 - grouper
72 - importas
73 - ineffassign
74 - ireturn
75 - lll
76 - loggercheck
77 - maintidx
78 - makezero
79 - misspell
80 - nakedret
81 - nestif
82 - nilerr
83 - nilnil
84 - nlreturn
85 - nolintlint
86 - nosprintfhostport
87 - paralleltest
88 - prealloc
89 - predeclared
90 - promlinter
91 - reassign
92 - revive
93 - staticcheck
94 - stylecheck
95 - tenv
96 - typecheck
97 - unconvert
98 - unparam
99 - unused
100 - usestdlibvars
101 - varnamelen
102 - wastedassign
103 - whitespace
104 - wrapcheck
105 - wsl
106
107 linters-settings:
108 nlreturn:
109 # Size of the block (including return statement that is still "OK") so no return split required.
110 # Default: 1
111 block-size: 2
112 wsl:
113 enforce-err-cuddling: true
114 allow-cuddle-declarations: true
115 allow-assign-and-call: true
116 allow-cuddle-with-calls:
117 - log.Println
118 - log.Printf
119 - RLock
120 - RUnlock
121 - Lock
122 - Unlock
123 allow-assign-and-anything: true
124 gofumpt:
125 extra-rules: true
126 lll:
127 line-length: 160
128 varnamelen:
129 ignore-decls:
130 - w io.Writer
131 - w io.WriteCloser
132 - w http.ResponseWriter
133 - r *http.Request
134 - r chi.Router
135 - r *chi.Mux
136 - i int
137
138 issues:
139 # List of regexps of issue texts to exclude.
140 exclude-rules:
141 # Exclude some linters from running on tests files.
142 - path: _test\.go
143 linters:
144 - nlreturn