From 4ffb3eb37d5362a6ab0e09b5e4035d801e4ec8e6 Mon Sep 17 00:00:00 2001 From: Vincent Demeester Date: Fri, 20 Dec 2024 14:00:25 +0100 Subject: [PATCH] .github/workflows: get go version from go.mod directive Signed-off-by: Vincent Demeester --- .github/workflows/codeql-analysis.yml | 2 +- .github/workflows/e2e-matrix.yml | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 20f28adc392..a8726170fe1 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -58,7 +58,7 @@ jobs: - name: Setup go uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5 with: - go-version: '1.22.x' + go-version-file: go.mod # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL diff --git a/.github/workflows/e2e-matrix.yml b/.github/workflows/e2e-matrix.yml index 2b56a80029a..2a55fad8ba6 100644 --- a/.github/workflows/e2e-matrix.yml +++ b/.github/workflows/e2e-matrix.yml @@ -46,15 +46,15 @@ jobs: steps: - name: Check out code onto GOPATH - uses: actions/checkout@v4 + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: path: ${{ github.workspace }}/src/github.com/tektoncd/pipeline - - name: Set up Go 1.22 - uses: actions/setup-go@v5 + - name: Set up Go (from go.mod) + uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5 with: - go-version: 1.22.5 + go-version-file: ${{ github.workspace }}/src/github.com/tektoncd/pipeline/go.mod - name: Install Dependencies working-directory: ./ @@ -107,4 +107,4 @@ jobs: cat $x echo '::endgroup::' done - fi \ No newline at end of file + fi