Skip to content

Commit a783cc4

Browse files
committed
Blacklist ioutil pkg in golangci-lint
This is to prevent anyone from accidentally importing the pkg Signed-off-by: Abhinav Nair <[email protected]>
1 parent 11f2f2d commit a783cc4

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

.golangci.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ linters:
77
disable-all: true
88
enable:
99
- deadcode
10+
- depguard
1011
- errcheck
1112
- gocyclo
1213
- gofmt
@@ -26,6 +27,13 @@ linters:
2627
- unused
2728
- varcheck
2829
linters-settings:
30+
depguard:
31+
list-type: blacklist
32+
include-go-root: true
33+
packages:
34+
# The io/ioutil package has been deprecated.
35+
# https://go.dev/doc/go1.16#ioutil
36+
- io/ioutil
2937
gocyclo:
3038
min-complexity: 16
3139
lll:

0 commit comments

Comments
 (0)