From 46e6ed29fa4fbd1ec8f3e6a102643281d472d721 Mon Sep 17 00:00:00 2001 From: "vitess-bot[bot]" <108069721+vitess-bot[bot]@users.noreply.github.com> Date: Wed, 6 Mar 2024 10:19:45 +0100 Subject: [PATCH] Ensure to use latest golangci-lint (#15413) Signed-off-by: Dirkjan Bussink --- .github/workflows/static_checks_etc.yml | 2 +- .golangci.yml | 1 - misc/git/hooks/golangci-lint | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/static_checks_etc.yml b/.github/workflows/static_checks_etc.yml index c238bd3852d..0aaaa6c4716 100644 --- a/.github/workflows/static_checks_etc.yml +++ b/.github/workflows/static_checks_etc.yml @@ -177,7 +177,7 @@ jobs: - name: Install golangci-lint if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.go_files == 'true' - run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.56.0 + run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.56.2 - name: Clean Env if: steps.skip-workflow.outputs.skip-workflow == 'false' && steps.changes.outputs.go_files == 'true' diff --git a/.golangci.yml b/.golangci.yml index ce554ad99ba..74c55100516 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -27,7 +27,6 @@ linters: # Extras - gofmt - goimports - - exportloopref - bodyclose # revive is a replacement for golint, but we do not run it in CI for now. diff --git a/misc/git/hooks/golangci-lint b/misc/git/hooks/golangci-lint index 3ad4775271a..d152cb965a3 100755 --- a/misc/git/hooks/golangci-lint +++ b/misc/git/hooks/golangci-lint @@ -16,7 +16,7 @@ GOLANGCI_LINT=$(command -v golangci-lint >/dev/null 2>&1) if [ $? -eq 1 ]; then echo "Downloading golangci-lint..." - go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.51.2 + go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.56.2 fi gofiles=$(git diff --cached --name-only --diff-filter=ACM | grep '^go/.*\.go$')