diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e706ac60..df17b2fe 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -22,8 +22,8 @@ env: GO_TEST_ARGS: -coverprofile coverage.out -covermode atomic TEST_GEM_DIR: ruby/testdata/example/ - # c.f. https://github.com/golangci/golangci-lint/blob/master/CHANGELOG.md - GOLANGCI_LINT_VERSION: v1.60 + # c.f. https://github.com/golangci/golangci-lint/blob/main/CHANGELOG.md + GOLANGCI_LINT_VERSION: v2.0 jobs: generate-matrix: @@ -136,7 +136,7 @@ jobs: - run: echo $BUILD_TAG - name: golangci-lint - uses: golangci/golangci-lint-action@v6 + uses: golangci/golangci-lint-action@v7 with: version: ${{ env.GOLANGCI_LINT_VERSION }} args: --build-tags ${{ env.BUILD_TAG }} --modules-download-mode=readonly diff --git a/.golangci.yml b/.golangci.yml index 3a9a9b9c..75c4a444 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -1,18 +1,31 @@ -linters-settings: - revive: - rules: - - name: exported - arguments: - - disableStutteringCheck - +version: "2" linters: enable: - - gofmt - revive - testifylint - wrapcheck - -issues: - include: - - EXC0012 # EXC0012 revive: Annoying issue about not having a comment. The rare codebase has such comments - - EXC0014 # EXC0014 revive: Annoying issue about not having a comment. The rare codebase has such comments + settings: + revive: + rules: + - name: exported + arguments: + - disableStutteringCheck + exclusions: + generated: lax + presets: + - common-false-positives + - legacy + - std-error-handling + paths: + - third_party$ + - builtin$ + - examples$ +formatters: + enable: + - gofmt + exclusions: + generated: lax + paths: + - third_party$ + - builtin$ + - examples$