-
Notifications
You must be signed in to change notification settings - Fork 4
/
.golangci.yml
23 lines (23 loc) · 1.67 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
linters:
disable-all: true
enable:
# - deadcode # Finds unused code
- errcheck # Errcheck is a program for checking for unchecked errors in go programs. These unchecked errors can be critical bugs in some cases
- gosimple # Linter for Go source code that specializes in simplifying a code
- govet # Vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string
- ineffassign # Detects when assignments to existing variables are not used
- staticcheck # Staticcheck is a go vet on steroids, applying a ton of static analysis checks
# - structcheck # Finds unused struct fields
- typecheck # Like the front-end of a Go compiler, parses and type-checks Go code
- unused # Checks Go code for unused constants, variables, functions and types
##- varcheck # Finds unused global variables and constants
## disabled by default
- errname # Checks that sentinel errors are prefixed with the Err and error types are suffixed with the Error.
- errorlint # errorlint is a linter for that can be used to find code that will cause problems with the error wrapping scheme introduced in Go 1.13.
- goconst # Finds repeated strings that could be replaced by a constant
- gocritic # Provides diagnostics that check for bugs, performance and style issues.
# - gosec # Inspects source code for security problems
- unconvert # Remove unnecessary type conversions
- unparam # Reports unused function parameters
- usestdlibvars # detect the possibility to use variables/constants from the Go standard library
# - wastedassign # wastedassign finds wasted assignment statements.