-
Notifications
You must be signed in to change notification settings - Fork 3
/
.golangci.yml
44 lines (42 loc) · 1.05 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
linters:
enable:
- depguard
- errcheck
- errorlint
- forbidigo
- gci
- gofmt
- goimports
- gosimple
- govet
- ineffassign
- staticcheck
- typecheck
- unused
- whitespace
linters-settings:
forbidigo:
# These are forbidden in non-test files
# If you have mock functions,etc that are meant to be used in tests please add them here
forbid:
- ^fmt\.Print.*$
- ^spew\.Dump$
- ^println$
depguard:
rules:
main:
deny:
- pkg: gopkg.in/yaml.v2
desc: please use gopkg.in/yaml.v3 instead
- pkg: github.com/pkg/errors
desc: please use errors from the standard library instead
- pkg: golang.org/x/xerrors
desc: please use errors from the standard library instead
- pkg: github.com/sirupsen/logrus
desc: please use log/slog from the standard library instead
issues:
exclude-rules:
# Exclude some linters from running on tests files.
- path: _test\.go
linters:
- forbidigo