-
Notifications
You must be signed in to change notification settings - Fork 0
/
.golangci.yml
71 lines (64 loc) · 1.69 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
linters-settings:
dupl:
threshold: 100
gocritic:
# Enable multiple checks by tags, run `GL_DEBUG=gocritic golangci-lint` run to see all tags and checks.
# Empty list by default. See https://github.com/go-critic/go-critic#usage -> section "Tags".
enabled-tags:
- performance
- diagnostic
- style
disabled-checks:
- emptyStringTest
gocyclo:
min-complexity: 15
golint:
min-confidence: 0
govet:
check-shadowing: true
goconst:
min-len: 2
min-occurrences: 3
goimports:
local-prefixes: github.com/matoous/linkfix
lll:
line-length: 140
maligned:
suggest-new: true
misspell:
locale: US
linters:
enable-all: true
disable:
# prealloc is not recommended by `golangci-lint` developers.
- prealloc
- gochecknoglobals
- wsl
# gomnd checks magic numbers which is any number in code, that is not first defined with some name
- gomnd
# This makes sense for packages and libraries but many of our dynamic errors are just for us to log if things
# go tits up. So when it comes to error: use common sense.
- goerr113
issues:
exclude-rules:
- path: _test\.go
linters:
- goconst
- dupl
- bodyclose
- depguard
- gomnd
- linters:
- lll
source: "https://[^ ]{100,}"
run:
modules-download-mode: readonly
timeout: 5m
# output configuration options
output:
# colored-line-number|line-number|json|tab|checkstyle|code-climate, default is "colored-line-number"
format: tab
# print lines of code with issue, default is true
print-issued-lines: true
# print linter name in the end of issue text, default is true
print-linter-name: true