From 4ddef6da7d01fbd3f1916af44e17bbe89336e409 Mon Sep 17 00:00:00 2001 From: Mustafa Elbehery Date: Tue, 17 Jun 2025 14:10:31 +0200 Subject: [PATCH] chore(CI): add gci formatter Signed-off-by: Mustafa Elbehery --- .github/workflows/golangci-lint.yml | 4 ++-- .golangci.yaml | 9 +++++++++ 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index 326c28b..094fc20 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -24,10 +24,10 @@ jobs: with: go-version: ${{ steps.goversion.outputs.goversion }} - name: golangci-lint - uses: golangci/golangci-lint-action@4696ba8babb6127d732c3c6dde519db15edab9ea # v6.5.1 + uses: golangci/golangci-lint-action@4afd733a84b1f43292c63897423277bb7f4313a9 # v8.0.0 with: # Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version - version: v1.64.5 + version: v2.1.6 # Optional: working directory, useful for monorepos # working-directory: somedir diff --git a/.golangci.yaml b/.golangci.yaml index 0008a47..8636763 100644 --- a/.golangci.yaml +++ b/.golangci.yaml @@ -1,4 +1,13 @@ --- +formatters: + enable: + - gci + settings: # please keep this alphabetized + gci: + sections: + - standard + - default + - prefix(go.etcd.io) issues: exclude-files: - "^zz_generated.*"