diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e186860d63..83493a3e8a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,9 +54,9 @@ jobs: go-version: 1.21.8 cache: false - name: golangci-lint - uses: golangci/golangci-lint-action@v3 + uses: golangci/golangci-lint-action@v4 with: - version: v1.55.2 + version: v1.57.2 args: --config=.golangci-strict.yml test: diff --git a/.golangci-strict.yml b/.golangci-strict.yml index d82b114fa3..ad278677a3 100644 --- a/.golangci-strict.yml +++ b/.golangci-strict.yml @@ -93,6 +93,21 @@ linters-settings: gocritic: enabled-checks: - ruleguard + disabled-checks: + - appendAssign + - assignOp + - badCond + - captLocal + - commentFormatting + - deprecatedComment + - elseif + - ifElseChain + - regexpMust + - singleCaseSwitch + - sloppyLen + - unlambda + - valSwap + - wrapperFunc settings: ruleguard: rules: '${configDir}/ruleguard/*.go' diff --git a/.golangci.yml b/.golangci.yml index 63f12390bf..012f09fbaa 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -65,42 +65,6 @@ linters-settings: - fieldalignment # detect Go structs that would take less memory if their fields were sorted gocritic: enabled-checks: - # start defaults - - appendAssign - - argOrder - - assignOp - - badCall - - badCond - - captLocal - - caseOrder - - codegenComment - - commentFormatting - - defaultCaseOrder - - deprecatedComment - - dupArg - - dupBranchBody - - dupCase - - dupSubExpr - - elseif - - exitAfterDefer - - flagDeref - - flagName - - ifElseChain - - mapKey - - newDeref - - offBy1 - - regexpMust - - singleCaseSwitch - - sloppyLen - - sloppyTypeAssert - - switchTrue - - typeSwitchVar - - underef - - unlambda - - unslice - - valSwap - - wrapperFunc - # end defaults - ruleguard settings: ruleguard: