-
Notifications
You must be signed in to change notification settings - Fork 2
/
.golangci.yaml
32 lines (32 loc) · 1.49 KB
/
.golangci.yaml
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
run:
timeout: 5m
linters:
disable-all: true
enable:
- unused # Finds unused code
- unconvert # Remove unnecessary type conversions
- unused # Checks Go code for unused constants, variables, functions and types
- ineffassign # Detects when assignments to existing variables are not used
- misspell # Finds commonly misspelled English words in comments
- gofmt # Gofmt checks whether code was gofmt-ed
- revive # Revive is a replacement for golint, a coding style checker
- errcheck # errcheck is a program for checking for unchecked errors in go programs.
- staticcheck # staticcheck is a go vet on steroids, applying a ton of static analysis checks
- govet # Vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string
- bodyclose # checks whether HTTP response body is closed successfully
- exhaustive # check exhaustiveness of enum switch statements
- stylecheck # Stylecheck is a replacement for golint
linters-settings:
errcheck:
# Disable warnings for `fmt` and `log` packages.
exclude-functions:
- fmt.Errorf
- fmt.Print
- fmt.Printf
- fmt.Println
- (github.com/pulumi/pulumi/sdk/v3/go/pulumi.Log).Debug
- (github.com/pulumi/pulumi/sdk/v3/go/pulumi.Log).Info
- (github.com/pulumi/pulumi/sdk/v3/go/pulumi.Log).Warn
- (github.com/pulumi/pulumi/sdk/v3/go/pulumi.Log).Error
staticcheck:
checks: ["all"]