From 38508c2d68a51eb8625f76fd950942e890085f0c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 5 May 2025 15:56:39 +0800 Subject: [PATCH] chore(deps): bump golangci/golangci-lint-action from 6 to 8 (#488) * chore(deps): bump golangci/golangci-lint-action from 6 to 8 Bumps [golangci/golangci-lint-action](https://github.com/golangci/golangci-lint-action) from 6 to 8. - [Release notes](https://github.com/golangci/golangci-lint-action/releases) - [Commits](https://github.com/golangci/golangci-lint-action/compare/v6...v8) --- updated-dependencies: - dependency-name: golangci/golangci-lint-action dependency-version: '8' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] * fix lint errors Signed-off-by: yxxhero --------- Signed-off-by: dependabot[bot] Signed-off-by: yxxhero Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: yxxhero --- .github/workflows/lint.yml | 5 ++- .golangci.yml | 74 +++++++++++++++++++++++--------------- 2 files changed, 47 insertions(+), 32 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index bea35f9..369f234 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -18,10 +18,9 @@ jobs: fetch-depth: '0' - name: Golangci lint - uses: golangci/golangci-lint-action@v6 + uses: golangci/golangci-lint-action@v8 with: - version: v1.54 - args: --verbose + version: v2.1.6 rust-lint: name: Rust Lint diff --git a/.golangci.yml b/.golangci.yml index b45866a..60d6333 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -1,37 +1,53 @@ +version: "2" run: - deadline: 3m modules-download-mode: readonly - -linters-settings: - gocyclo: - min-complexity: 60 - gci: - sections: - - standard - - default - +linters: + default: none + enable: + - errcheck + - goconst + - gocyclo + - govet + - misspell + - staticcheck + settings: + gocyclo: + min-complexity: 60 + exclusions: + generated: lax + presets: + - comments + - common-false-positives + - legacy + - std-error-handling + rules: + - linters: + - staticcheck + text: 'SA1019:' + paths: + - third_party$ + - builtin$ + - examples$ issues: new: true - exclude-rules: - - linters: - - staticcheck - text: "SA1019:" - -linters: - disable-all: true +formatters: enable: - gci - gofmt - - golint - - misspell - - govet - - goconst - - deadcode - - gocyclo - - staticcheck - - errcheck - + settings: + gci: + sections: + - standard + - default + exclusions: + generated: lax + paths: + - third_party$ + - builtin$ + - examples$ output: - format: colored-line-number - print-issued-lines: true - print-linter-name: true + formats: + text: + path: stdout + print-linter-name: true + print-issued-lines: true \ No newline at end of file