Skip to content

Commit

Permalink
Merge pull request cri-o#8835 from saschagrunert/lint-config
Browse files Browse the repository at this point in the history
Update golangci-lint to v1.62.2 and config
  • Loading branch information
saschagrunert authored Dec 11, 2024
2 parents 8d332ee + c5bdce0 commit 6fe4033
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 75 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
pull_request:
env:
GO_VERSION: "1.23"
GOLANGCI_LINT_VERSION: v1.62.0
GOLANGCI_LINT_VERSION: v1.62.2
permissions:
contents: read

Expand Down
76 changes: 4 additions & 72 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,78 +139,10 @@ linters-settings:
disabled: false
arguments: [22]
gocritic:
enabled-checks:
- appendCombine
- badLock
- badRegexp
- badSorting
- badSyncOnceFunc
- boolExprSimplify
- builtinShadow
- builtinShadowDecl
- commentedOutCode
- commentedOutImport
- deferInLoop
- deferUnlambda
- docStub
- dupImport
- dynamicFmtString
- emptyDecl
- emptyFallthrough
- emptyStringTest
- equalFold
- evalOrder
- exposedSyncMutex
- externalErrorReassign
- hexLiteral
- httpNoBody
- hugeParam
- importShadow
- indexAlloc
- initClause
- methodExprCall
- nestingReduce
- nilValReturn
- octalLiteral
- paramTypeCombine
- preferDecodeRune
- preferFilepathJoin
- preferFprint
- preferStringWriter
- preferWriteByte
- ptrToRefParam
- rangeExprCopy
- rangeValCopy
- redundantSprint
- regexpPattern
- regexpSimplify
- returnAfterHttpError
- ruleguard
- sliceClear
- sloppyReassign
- sortSlice
- sprintfQuotedString
- sqlQuery
- stringConcatSimplify
- stringXbytes
- stringsCompare
- syncMapLoadAndDelete
- timeExprSimplify
- todoCommentWithoutDetail
- tooManyResultsChecker
- truncateCmp
- typeAssertChain
- typeDefFirst
- typeUnparen
- uncheckedInlineErr
- unlabelStmt
- unnamedResult
- unnecessaryBlock
- unnecessaryDefer
- weakCond
- yodaStyleExpr
# - filepathJoin
# - whyNoLint
enable-all: true
disabled-checks:
- filepathJoin
- whyNoLint
gocyclo:
min-complexity: 177
nakedret:
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ GO_MD2MAN ?= ${BUILD_BIN_PATH}/go-md2man
GINKGO := ${BUILD_BIN_PATH}/ginkgo
MOCKGEN := ${BUILD_BIN_PATH}/mockgen
GOLANGCI_LINT := ${BUILD_BIN_PATH}/golangci-lint
GOLANGCI_LINT_VERSION := v1.62.0
GOLANGCI_LINT_VERSION := v1.62.2
GO_MOD_OUTDATED := ${BUILD_BIN_PATH}/go-mod-outdated
GO_MOD_OUTDATED_VERSION := 0.9.0
GOSEC := ${BUILD_BIN_PATH}/gosec
Expand Down
2 changes: 1 addition & 1 deletion dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ dependencies:
match: buildGo123Module

- name: golangci-lint
version: v1.62.0
version: v1.62.2
refPaths:
- path: .github/workflows/verify.yml
match: GOLANGCI_LINT_VERSION
Expand Down

0 comments on commit 6fe4033

Please sign in to comment.