diff --git a/.github/env b/.github/env new file mode 100644 index 000000000..b321f6ef7 --- /dev/null +++ b/.github/env @@ -0,0 +1,2 @@ +GOLANG_VERSION=1.24 +GOLANGCI_LINT_VERSION=v2.0.2 diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index b654bf4d6..6ed7092dc 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -19,10 +19,12 @@ jobs: steps: - name: Checkout source code uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # pin@v4.2.2 + - name: Add variables to environment file + run: cat ".github/env" >> "$GITHUB_ENV" - name: Setup Go uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # pin@5.4.0 with: - go-version: '1.23' + go-version: '${{ env.GOLANG_VERSION }}' check-latest: true - name: Test source headers are present run: make test-source-headers diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index a3f6ba359..7ecbcb95d 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -14,13 +14,14 @@ jobs: steps: - name: Checkout uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # pin@v4.2.2 - + - name: Add variables to environment file + run: cat ".github/env" >> "$GITHUB_ENV" - name: Setup Go uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # pin@5.4.0 with: - go-version: '1.23' + go-version: '${{ env.GOLANG_VERSION }}' check-latest: true - name: golangci-lint uses: golangci/golangci-lint-action@1481404843c368bc19ca9406f87d6e0fc97bdcfd #pin@7.0.0 with: - version: v2.0.2 + version: ${{ env.GOLANGCI_LINT_VERSION }} diff --git a/.github/workflows/govulncheck.yml b/.github/workflows/govulncheck.yml index b376c7b8e..8d183e244 100644 --- a/.github/workflows/govulncheck.yml +++ b/.github/workflows/govulncheck.yml @@ -13,10 +13,12 @@ jobs: name: govulncheck runs-on: ubuntu-latest steps: + - name: Add variables to environment file + run: cat ".github/env" >> "$GITHUB_ENV" - name: Setup Go uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # pin@5.4.0 with: - go-version: '1.23' + go-version: '${{ env.GOLANG_VERSION }}' check-latest: true - name: govulncheck uses: golang/govulncheck-action@b625fbe08f3bccbe446d94fbf87fcc875a4f50ee # pin@1.0.4 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 63e5c0e26..38d13a175 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -24,14 +24,15 @@ jobs: with: fetch-depth: 0 + - name: Add variables to environment file + run: cat ".github/env" >> "$GITHUB_ENV" + - name: Setup Go uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # pin@5.4.0 with: - go-version: '1.23' - + go-version: '${{ env.GOLANG_VERSION }}' - name: Run unit tests run: make test-coverage - - name: Build Helm Binaries run: | set -eu -o pipefail @@ -80,10 +81,13 @@ jobs: - name: Checkout source code uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # pin@v4.2.2 + - name: Add variables to environment file + run: cat ".github/env" >> "$GITHUB_ENV" + - name: Setup Go uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # pin@5.4.0 with: - go-version: '1.23' + go-version: '${{ env.GOLANG_VERSION }}' check-latest: true - name: Run unit tests diff --git a/go.mod b/go.mod index adc06d0e5..01f6386ae 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module helm.sh/helm/v4 -go 1.23.7 +go 1.24.0 require ( github.com/AdaLogics/go-fuzz-headers v0.0.0-20230811130428-ced1acdcaa24