Skip to content

Commit

Permalink
Fix golangci-lint check and update config
Browse files Browse the repository at this point in the history
The .golangci.yml now reflects all linters, whereas the lint issue for
the deprecated protobuf package has been disabled. This is reasoned
because testgrid still uses the package and we have no chance to fix it
within this repository.

Signed-off-by: Sascha Grunert <sgrunert@suse.com>
  • Loading branch information
saschagrunert committed Sep 18, 2020
1 parent b2b2fbb commit cb1cc47
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
15 changes: 15 additions & 0 deletions .golangci.yml
Expand Up @@ -13,6 +13,7 @@ issues:
linters:
disable-all: true
enable:
- asciicheck
- bodyclose
- deadcode
- depguard
Expand All @@ -24,8 +25,10 @@ linters:
- gocyclo
- godox
- gofmt
- goheader
- goimports
- golint
- gomodguard
- goprintffuncname
- gosimple
- govet
Expand All @@ -36,6 +39,7 @@ linters:
- nakedret
- prealloc
- rowserrcheck
- sqlclosecheck
- staticcheck
- structcheck
- stylecheck
Expand All @@ -45,14 +49,25 @@ linters:
- unused
- varcheck
- whitespace
# - exhaustive
# - exportloopref
# - funlen
# - gci
# - gochecknoglobals
# - gochecknoinits
# - gocognit
# - godot
# - goerr113
# - gofumpt
# - gomnd
# - gosec
# - lll
# - nestif
# - nlreturn
# - noctx
# - nolintlint
# - scopelint
# - testpackage
# - wsl
linters-settings:
godox:
Expand Down
2 changes: 1 addition & 1 deletion pkg/testgrid/testgrid_test.go
Expand Up @@ -21,7 +21,7 @@ import (
"testing"

pb "github.com/GoogleCloudPlatform/testgrid/pb/config"
"github.com/golang/protobuf/proto"
"github.com/golang/protobuf/proto" // nolint: staticcheck
"github.com/stretchr/testify/require"

"k8s.io/release/pkg/git"
Expand Down

0 comments on commit cb1cc47

Please sign in to comment.