From 36552da309c4faa028b8309252302f2a30de823d Mon Sep 17 00:00:00 2001 From: Ludovic Fernandez Date: Fri, 5 Dec 2025 16:45:51 +0100 Subject: [PATCH] chore: update workflows (#2741) --- .github/workflows/documentation.yml | 8 ++------ .github/workflows/go-cross.yml | 9 ++------- .github/workflows/pr.yml | 27 ++++++++++----------------- .github/workflows/release.yml | 8 +++----- .golangci.yml | 3 +++ 5 files changed, 20 insertions(+), 35 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index c0bbbfbdc..4f9d444fc 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -17,15 +17,11 @@ jobs: steps: - # https://github.com/marketplace/actions/checkout - - name: Check out code - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 0 - # https://github.com/marketplace/actions/setup-go-environment - - name: Set up Go ${{ env.GO_VERSION }} - uses: actions/setup-go@v5 + - uses: actions/setup-go@v6 with: go-version: ${{ env.GO_VERSION }} diff --git a/.github/workflows/go-cross.yml b/.github/workflows/go-cross.yml index 30ec652a2..9dee85035 100644 --- a/.github/workflows/go-cross.yml +++ b/.github/workflows/go-cross.yml @@ -20,13 +20,8 @@ jobs: os: [ubuntu-latest, macos-latest, windows-latest] steps: - # https://github.com/marketplace/actions/checkout - - name: Checkout code - uses: actions/checkout@v4 - - # https://github.com/marketplace/actions/setup-go-environment - - name: Set up Go ${{ matrix.go-version }} - uses: actions/setup-go@v5 + - uses: actions/checkout@v6 + - uses: actions/setup-go@v6 with: go-version: ${{ matrix.go-version }} diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 91977bc28..626d9f6e9 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest env: GO_VERSION: stable - GOLANGCI_LINT_VERSION: v2.6.0 + GOLANGCI_LINT_VERSION: v2.7.1 HUGO_VERSION: 0.148.2 CGO_ENABLED: 0 LEGO_E2E_TESTS: CI @@ -21,40 +21,33 @@ jobs: steps: - # https://github.com/marketplace/actions/checkout - - name: Check out code - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 0 - # https://github.com/marketplace/actions/setup-go-environment - - name: Set up Go ${{ env.GO_VERSION }} - uses: actions/setup-go@v5 + - uses: actions/setup-go@v6 with: go-version: ${{ env.GO_VERSION }} - name: Check and get dependencies run: | - go mod tidy - git diff --exit-code go.mod - git diff --exit-code go.sum + go mod tidy --diff - name: Generate and Check generated elements run: | make generate-dns git diff --exit-code - # https://golangci-lint.run/usage/install#other-ci - - name: Install golangci-lint ${{ env.GOLANGCI_LINT_VERSION }} - run: | - curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin ${GOLANGCI_LINT_VERSION} - golangci-lint --version + - uses: golangci/golangci-lint-action@v9 + with: + version: ${{ env.GOLANGCI_LINT_VERSION }} + install-only: true - name: Install Pebble - run: go install github.com/letsencrypt/pebble/v2/cmd/pebble@v2.7.0 + run: go install github.com/letsencrypt/pebble/v2/cmd/pebble@v2.8.0 - name: Install challtestsrv - run: go install github.com/letsencrypt/pebble/v2/cmd/pebble-challtestsrv@v2.7.0 + run: go install github.com/letsencrypt/pebble/v2/cmd/pebble-challtestsrv@v2.8.0 - name: Set up a Memcached server uses: niden/actions-memcached@v7 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ca2e1867e..3ba055979 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -42,13 +42,11 @@ jobs: docker-images: true swap-storage: false - - name: Check out code - uses: actions/checkout@v4 + - uses: actions/checkout@v6 with: fetch-depth: 0 - - name: Set up Go ${{ env.GO_VERSION }} - uses: actions/setup-go@v5 + - uses: actions/setup-go@v6 with: go-version: ${{ env.GO_VERSION }} @@ -71,7 +69,7 @@ jobs: - name: Run GoReleaser uses: goreleaser/goreleaser-action@v6 with: - version: v2.12.3 + version: v2.13.0 args: release -p 1 --clean --timeout=90m env: GITHUB_TOKEN: ${{ secrets.GH_TOKEN_REPO }} diff --git a/.golangci.yml b/.golangci.yml index ceb7cad85..b851169ff 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -180,6 +180,9 @@ linters: text: Error return value of `fmt.Fprintln` is not checked linters: - errcheck + - text: "var-naming: avoid meaningless package names" + linters: + - revive - path: certcrypto/crypto.go text: (tlsFeatureExtensionOID|ocspMustStapleFeature) is a global variable linters: