forked from Altinity/clickhouse-backup
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.golangci.yml
126 lines (122 loc) · 2.65 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
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
117
118
119
120
121
122
123
124
125
126
run:
concurrency: 4
timeout: 1m
issues-exit-code: 1
tests: true
build-tags: []
skip-dirs:
- test/integration
skip-dirs-use-default: true
skip-files: []
modules-download-mode: readonly
output:
format: colored-line-number
print-issued-lines: true
print-linter-name: true
linters-settings:
govet:
check-shadowing: false
settings:
printf:
funcs:
- (github.com/golangci/golangci-lint/pkg/logutils.Log).Infof
- (github.com/golangci/golangci-lint/pkg/logutils.Log).Warnf
- (github.com/golangci/golangci-lint/pkg/logutils.Log).Errorf
- (github.com/golangci/golangci-lint/pkg/logutils.Log).Fatalf
enable:
- atomicalign
enable-all: false
disable:
- shadow
disable-all: false
golint:
min-confidence: 0.8
gofmt:
simplify: true
gocyclo:
min-complexity: 30
gocognit:
min-complexity: 30
dupl:
threshold: 150
goconst:
min-len: 3
min-occurrences: 3
misspell:
locale: US
ignore-words: []
unused:
check-exported: false
unparam:
check-exported: false
nakedret:
max-func-lines: 30
prealloc:
simple: true
range-loops: true # Report preallocation suggestions on range loops, true by default
for-loops: false # Report preallocation suggestions on for loops, false by default
gocritic:
enabled-checks: []
disabled-checks: []
enabled-tags:
- performance
settings: # settings passed to gocritic
captLocal: # must be valid enabled check name
paramsOnly: true
rangeValCopy:
sizeThreshold: 32
dogsled:
max-blank-identifiers: 2
whitespace:
multi-if: false # Enforces newlines (or comments) after every multi-line if statement
multi-func: false # Enforces newlines (or comments) after every multi-line function signature
linters:
enable:
- dupl
- megacheck
- govet
- gofmt
- goimports
- misspell
- prealloc
- stylecheck
- unconvert
- whitespace
disable:
- maligned
- errcheck
- scopelint
- gosec
disable-all: false
presets:
- bugs
- unused
fast: true
issues:
exclude: []
exclude-rules:
- path: _test\.go
linters:
- gocyclo
- errcheck
- dupl
- gosec
- path: internal/hmac/
text: "weak cryptographic primitive"
linters:
- gosec
- linters:
- staticcheck
text: "SA9003:"
- linters:
- gosec
text: "G104:"
- linters:
- lll
source: "^//go:generate "
exclude-use-default: false
max-issues-per-linter: 0
max-same-issues: 0
new: false
new-from-rev:
new-from-patch: