Skip to content

Commit b9cc2f2

Browse files
committed
ci: add new linters to golangci-lint
1 parent c4b4c7e commit b9cc2f2

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

.golangci.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ linters:
1818
- errcheck # Errcheck is a program for checking for unchecked errors in go programs. These unchecked errors can be critical bugs in some cases [fast: false, auto-fix: false]
1919
- errchkjson # Checks types passed to the json encoding functions. Reports unsupported types and optionally reports occasions, where the check for the returned error can be omitted. [fast: false, auto-fix: false]
2020
- errname # Checks that sentinel errors are prefixed with the `Err` and error types are suffixed with the `Error`. [fast: false, auto-fix: false]
21+
- exptostd # Detects functions from golang.org/x/exp/ that can be replaced by std functions. [auto-fix]
2122
- forbidigo # Forbids identifiers [fast: true, auto-fix: false]
2223
- gci # Gci controls golang package import order and makes it always deterministic. [fast: true, auto-fix: false]
2324
- gocheckcompilerdirectives # Checks that go compiler directive comments (//go:) are valid. [fast: true, auto-fix: false]
@@ -74,6 +75,7 @@ linters:
7475
- unconvert # Remove unnecessary type conversions [fast: false, auto-fix: false]
7576
- unused #(megacheck): Checks Go code for unused constants, variables, functions and types [fast: false, auto-fix: false]
7677
- usestdlibvars # A linter that detect the possibility to use variables/constants from the Go standard library. [fast: true, auto-fix: false]
78+
- usetesting # Reports uses of functions with replacement inside the testing package. [auto-fix]
7779
- wastedassign # wastedassign finds wasted assignment statements. [fast: false, auto-fix: false]
7880
- whitespace # Tool for detection of leading and trailing whitespace [fast: true, auto-fix: true]
7981
- zerologlint # Detects the wrong usage of `zerolog` that a user forgets to dispatch with `Send` or `Msg` [fast: false, auto-fix: false]

0 commit comments

Comments
 (0)