-
Notifications
You must be signed in to change notification settings - Fork 0
/
.golangci.yml
66 lines (62 loc) · 1.72 KB
/
.golangci.yml
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
linters:
# Disable all linters.
disable-all: true
# Enable specific linter
enable:
- errcheck
- wrapcheck
- ineffassign
- unused
run:
# Number of operating system threads (`GOMAXPROCS`) that can execute golangci-lint simultaneously.
# If it is explicitly set to 0 (i.e. not the default) then golangci-lint will automatically set the value to match Linux container CPU quota.
# Default: the number of logical CPUs in the machine
concurrency: 8
# Timeout for analysis, e.g. 30s, 5m.
# Default: 1m
timeout: 5m
go: "1.22.0"
output:
# Show statistics per linter.
show-stats: true
# Sort results by the order defined in `sort-order`.
sort-results: true
# Order to use when sorting results.
# Require `sort-results` to `true`.
# Possible values: `file`, `linter`, and `severity`.
#
# If the severity values are inside the following list, they are ordered in this order:
# 1. error
# 2. warning
# 3. high
# 4. medium
# 5. low
# Either they are sorted alphabetically.
sort-order:
- linter
- file
- severity
issues:
# Maximum issues count per one linter.
# Set to 0 to disable.
# Default: 50
max-issues-per-linter: 0
# Maximum count of issues with the same text.
# Set to 0 to disable.
# Default: 3
max-same-issues: 0
exclude-rules:
- linters:
- lll
source: "^//go:generate "
exclude-dirs:
- "tools"
exclude-files:
- ".*\\.gen\\.go$"
- ".*\\.ridl$"
linters-settings:
errcheck:
# List of functions to exclude from checking, where each entry is a single function to exclude.
# See https://github.com/kisielk/errcheck#excluding-functions for details.
exclude-functions:
- (net/http.ResponseWriter).Write