-
Notifications
You must be signed in to change notification settings - Fork 2
/
.golangci.yml
69 lines (66 loc) · 1.64 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
run:
timeout: 5m
skip-dirs:
- test/*
skip-files: [zz_generated.deepcopy.go]
linters:
# Enable all linters
presets:
- bugs
- comment
- complexity
- error
- format
- import
- metalinter
- module
- performance
- sql
- style
- test
- unused
# Deal with deprecation warnings
enable:
- exportloopref
disable:
- golint # replaced with revive in 1.40
- interfacer
- maligned
- scopelint
- gofumpt # as per operator
- lll # long lines as per operator
- gochecknoglobals # global variables as per operator (and for logging)
- exhaustivestruct
linters-settings:
# Code duplication filter catches a lot of duplication in test
# this needs refactoring at some point.
dupl:
threshold: 500
issues:
exclude-rules:
# Deep copies have 'in' as the receiver, ours have something else.
# This linter should ignore the auto generated stuff, but doesn't.
- text: ST1016
linters:
- stylecheck
# Things that are parameterized, and don't need to be. This is probably
# a gap in testing.
- text: always receives
linters:
- unparam
# Test is exempt from proper error handling.
- path: test/.*
linters:
- goerr113
# disables a rule that requires all exported consts/methods to be commented
- text: exported
linters:
- revive
# disables a rule that looks at json tags and complains about camel case
# since these values come from Couchbase Server, there is no fixing it.
- text: json
linters:
- tagliatelle
- text: parallel
linters:
- parrelleltest