-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.golangci.yaml
74 lines (61 loc) · 1.55 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
run:
timeout: 15s
modules-download-mode: readonly
# Include test files or not. Default: true
tests: true
skip-dirs:
- .custom-hooks
- .github
- .task
- .trunk
- .vscode
- assets
- build
- dist
- templates
- tools
# Which files to skip: they will be analyzed, but issues from them won't be reported.
# Default value is empty list,
# but there is no need to include all autogenerated files,
# we confidently recognize autogenerated files.
# If it's not please let us know.
# "/" will be replaced by current OS file path separator to properly work on Windows.
# skip-files:
# - tools/**/*.go
allow-parallel-runners: true
concurrency: 8
linters:
disable-all: true
fast: true
enable:
- gocyclo
- govet
- maintidx
- misspell
- unused
- unparam
severity:
default-severity: warning
case-sensitive: false
linters-settings:
gocyclo:
min-complexity: 20
funlen:
lines: 100
statements: 80
gocritic:
disabled-checks:
- exitAfterDefer
gosec:
severity: medium
config:
G301: "0755" # Maximum allowed permissions mode for os.Mkdir and os.MkdirAll - Default: "0750"
G302: "0644" # Maximum allowed permissions mode for os.OpenFile and os.Chmod - Default: "0600"
G306: "0644" # Maximum allowed permissions mode for os.WriteFile and ioutil.WriteFile - Default: "0600"
maintidx:
under: 25
misspell:
locale: US
nestif:
max-nesting: 3
min-complexity: 4 # Minimal complexity of if statements to report. - Default: 5