Skip to content

Commit

Permalink
build: update linter config and remove deprecated linters
Browse files Browse the repository at this point in the history
  • Loading branch information
ghouscht committed Dec 6, 2021
1 parent ce5ac8d commit dc7c2a2
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
23 changes: 12 additions & 11 deletions .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,21 @@ linters-settings:
- hugeParam
gocyclo:
min-complexity: 15
golint:
revive:
min-confidence: 0.8
govet:
check-shadowing: true
lll:
line-length: 140
maligned:
suggest-new: true
misspell:
locale: US
nolintlint:
allow-leading-space: false
require-explanation: true
allow-no-explanation:
- gocognit
- funlen
- gocyclo

linters:
disable-all: true
Expand All @@ -48,29 +53,26 @@ linters:
- dupl
- errcheck
- funlen
# - gochecknoglobals
- nolintlint
- gochecknoglobals
- gochecknoinits
- gocognit
- goconst
- gocritic
- gocyclo
# - godox
- gofmt
- goimports
- golint
- revive
- goprintffuncname
- gosec
- gosimple
- govet
- ineffassign
- interfacer
# - lll
- maligned
- misspell
- nakedret
- prealloc
- rowserrcheck
- scopelint
- exportloopref
- staticcheck
- structcheck
- stylecheck
Expand All @@ -81,7 +83,6 @@ linters:
- varcheck
- whitespace
- wsl

issues:
exclude:
# Very commonly not checked.
Expand Down
2 changes: 1 addition & 1 deletion cmd/kuota-calc.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
"k8s.io/cli-runtime/pkg/genericclioptions"
)

var (
const (
kuotaCalcExample = ` # provide a simple/complex deployment by piping it to kuota-calc (used as kubectl plugin)
cat deployment.yaml | kubectl %[1]s
Expand Down
3 changes: 1 addition & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,8 @@ import (
"k8s.io/cli-runtime/pkg/genericclioptions"
)

//nolint:gochecknoglobals
//nolint:gochecknoglobals // Set by goreleaser on build
var (
// set by goreleaser on build
version, date, commit string = "master", "?", "?"
)

Expand Down

0 comments on commit dc7c2a2

Please sign in to comment.