From 1ce76c55c11f99371e65f7857e099bb6302226f0 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Wed, 30 Nov 2022 14:31:57 +0000 Subject: [PATCH] actions: use go-version-file: .go-version (#33879) see https://github.com/actions/setup-go/pull/295 (cherry picked from commit 01056086d67a8c285dd480d01e161e80be9013f5) --- .github/workflows/check-audtibeat.yml | 4 +--- .github/workflows/check-default.yml | 4 +--- .github/workflows/check-dev-tools.yml | 4 +--- .github/workflows/check-docs.yml | 4 +--- .github/workflows/check-filebeat.yml | 4 +--- .github/workflows/check-heartbeat.yml | 4 +--- .github/workflows/check-libbeat.yml | 4 +--- .github/workflows/check-metricbeat.yml | 4 +--- .github/workflows/check-packetbeat.yml | 4 +--- .github/workflows/check-winlogbeat.yml | 4 +--- .github/workflows/check-xpack-auditbeat.yml | 4 +--- .github/workflows/check-xpack-dockerlogbeat.yml | 4 +--- .github/workflows/check-xpack-filebeat.yml | 4 +--- .github/workflows/check-xpack-functionbeat.yml | 4 +--- .github/workflows/check-xpack-heartbeat.yml | 4 +--- .github/workflows/check-xpack-libbeat.yml | 4 +--- .github/workflows/check-xpack-metricbeat.yml | 4 +--- .github/workflows/check-xpack-osquerybeat.yml | 4 +--- .github/workflows/check-xpack-packetbeat.yml | 4 +--- .github/workflows/check-xpack-winlogbeat.yml | 4 +--- .github/workflows/golangci-lint.yml | 7 +------ .github/workflows/macos-auditbeat.yml | 4 +--- .github/workflows/macos-filebeat.yml | 4 +--- .github/workflows/macos-heartbeat.yml | 4 +--- .github/workflows/macos-metricbeat.yml | 4 +--- .github/workflows/macos-packetbeat.yml | 4 +--- .github/workflows/macos-xpack-auditbeat.yml | 4 +--- .github/workflows/macos-xpack-filebeat.yml | 4 +--- .github/workflows/macos-xpack-functionbeat.yml | 4 +--- .github/workflows/macos-xpack-heartbeat.yml | 4 +--- .github/workflows/macos-xpack-metricbeat.yml | 4 +--- .github/workflows/macos-xpack-osquerybeat.yml | 4 +--- .github/workflows/macos-xpack-packetbeat.yml | 4 +--- 33 files changed, 33 insertions(+), 102 deletions(-) diff --git a/.github/workflows/check-audtibeat.yml b/.github/workflows/check-audtibeat.yml index 20e8459d557..3941fcdd492 100644 --- a/.github/workflows/check-audtibeat.yml +++ b/.github/workflows/check-audtibeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-default.yml b/.github/workflows/check-default.yml index 304b5382c4a..56bf10ab779 100644 --- a/.github/workflows/check-default.yml +++ b/.github/workflows/check-default.yml @@ -17,11 +17,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check-default run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-dev-tools.yml b/.github/workflows/check-dev-tools.yml index df71c821a10..4f0ba423466 100644 --- a/.github/workflows/check-dev-tools.yml +++ b/.github/workflows/check-dev-tools.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-docs.yml b/.github/workflows/check-docs.yml index 4d56b80fa31..e3207662f7c 100644 --- a/.github/workflows/check-docs.yml +++ b/.github/workflows/check-docs.yml @@ -17,11 +17,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Install libpcap-dev run: sudo apt-get install -y libpcap-dev - name: Install libsystemd-dev diff --git a/.github/workflows/check-filebeat.yml b/.github/workflows/check-filebeat.yml index 6eca3a3d97c..aef79c3cb61 100644 --- a/.github/workflows/check-filebeat.yml +++ b/.github/workflows/check-filebeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Install libsystemd-dev run: sudo apt-get install -y libsystemd-dev - name: Run check/update diff --git a/.github/workflows/check-heartbeat.yml b/.github/workflows/check-heartbeat.yml index a0242812a52..c975398fc2b 100644 --- a/.github/workflows/check-heartbeat.yml +++ b/.github/workflows/check-heartbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-libbeat.yml b/.github/workflows/check-libbeat.yml index ec76fbefbc9..0ebb45e8b2c 100644 --- a/.github/workflows/check-libbeat.yml +++ b/.github/workflows/check-libbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Install libpcap-dev run: sudo apt-get install -y libpcap-dev - name: Run check/update diff --git a/.github/workflows/check-metricbeat.yml b/.github/workflows/check-metricbeat.yml index 54f4753531d..452f0dbedc1 100644 --- a/.github/workflows/check-metricbeat.yml +++ b/.github/workflows/check-metricbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-packetbeat.yml b/.github/workflows/check-packetbeat.yml index 847e13e503f..d2d8db8366a 100644 --- a/.github/workflows/check-packetbeat.yml +++ b/.github/workflows/check-packetbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Install libpcap-dev run: sudo apt-get install -y libpcap-dev - name: Run check/update diff --git a/.github/workflows/check-winlogbeat.yml b/.github/workflows/check-winlogbeat.yml index 41d7b95c0dd..e048d585fa8 100644 --- a/.github/workflows/check-winlogbeat.yml +++ b/.github/workflows/check-winlogbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-xpack-auditbeat.yml b/.github/workflows/check-xpack-auditbeat.yml index 1902de3942e..eed9628eb62 100644 --- a/.github/workflows/check-xpack-auditbeat.yml +++ b/.github/workflows/check-xpack-auditbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Install librpm-dev run: sudo apt-get install -y librpm-dev - name: Run check/update diff --git a/.github/workflows/check-xpack-dockerlogbeat.yml b/.github/workflows/check-xpack-dockerlogbeat.yml index e0b64b7847e..44760e6c5e6 100644 --- a/.github/workflows/check-xpack-dockerlogbeat.yml +++ b/.github/workflows/check-xpack-dockerlogbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-xpack-filebeat.yml b/.github/workflows/check-xpack-filebeat.yml index cd63315b0cd..69a8f33669a 100644 --- a/.github/workflows/check-xpack-filebeat.yml +++ b/.github/workflows/check-xpack-filebeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Install libpcap-dev run: sudo apt-get install -y libpcap-dev - name: Run check/update diff --git a/.github/workflows/check-xpack-functionbeat.yml b/.github/workflows/check-xpack-functionbeat.yml index 5ce27961a21..089828088d6 100644 --- a/.github/workflows/check-xpack-functionbeat.yml +++ b/.github/workflows/check-xpack-functionbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-xpack-heartbeat.yml b/.github/workflows/check-xpack-heartbeat.yml index 8a3eceb499e..c9b77cbebb3 100644 --- a/.github/workflows/check-xpack-heartbeat.yml +++ b/.github/workflows/check-xpack-heartbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-xpack-libbeat.yml b/.github/workflows/check-xpack-libbeat.yml index 4428b8ad900..11359887ef0 100644 --- a/.github/workflows/check-xpack-libbeat.yml +++ b/.github/workflows/check-xpack-libbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-xpack-metricbeat.yml b/.github/workflows/check-xpack-metricbeat.yml index e3bd576c386..f61967a5eec 100644 --- a/.github/workflows/check-xpack-metricbeat.yml +++ b/.github/workflows/check-xpack-metricbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-xpack-osquerybeat.yml b/.github/workflows/check-xpack-osquerybeat.yml index b97ec590526..e5c87bcf5bd 100644 --- a/.github/workflows/check-xpack-osquerybeat.yml +++ b/.github/workflows/check-xpack-osquerybeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update run: | go install github.com/magefile/mage diff --git a/.github/workflows/check-xpack-packetbeat.yml b/.github/workflows/check-xpack-packetbeat.yml index 5469bdaf80e..c3f847786c3 100644 --- a/.github/workflows/check-xpack-packetbeat.yml +++ b/.github/workflows/check-xpack-packetbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Install libpcap-dev run: sudo apt-get install -y libpcap-dev - name: Run check/update diff --git a/.github/workflows/check-xpack-winlogbeat.yml b/.github/workflows/check-xpack-winlogbeat.yml index 3a18353df6b..8656675c3a1 100644 --- a/.github/workflows/check-xpack-winlogbeat.yml +++ b/.github/workflows/check-xpack-winlogbeat.yml @@ -15,11 +15,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - name: Run check/update uses: magefile/mage-action@v2 with: diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index 981aceb49e6..82a04024ba7 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -28,14 +28,9 @@ jobs: - uses: actions/checkout@v3 - # Uses Go version from the repository. - - name: Read .go-version file - id: goversion - run: echo "::set-output name=version::$(cat .go-version)" - - uses: actions/setup-go@v3 with: - go-version: "${{ steps.goversion.outputs.version }}" + go-version-file: .go-version - name: golangci-lint env: diff --git a/.github/workflows/macos-auditbeat.yml b/.github/workflows/macos-auditbeat.yml index 3d01b6bc4e5..994ca6dbebc 100644 --- a/.github/workflows/macos-auditbeat.yml +++ b/.github/workflows/macos-auditbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-filebeat.yml b/.github/workflows/macos-filebeat.yml index 2c5d6b8c181..6b43f5bb6c6 100644 --- a/.github/workflows/macos-filebeat.yml +++ b/.github/workflows/macos-filebeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-heartbeat.yml b/.github/workflows/macos-heartbeat.yml index a3d612537a2..c8e346a4402 100644 --- a/.github/workflows/macos-heartbeat.yml +++ b/.github/workflows/macos-heartbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-metricbeat.yml b/.github/workflows/macos-metricbeat.yml index 56c3100ac5c..59a225e1601 100644 --- a/.github/workflows/macos-metricbeat.yml +++ b/.github/workflows/macos-metricbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-packetbeat.yml b/.github/workflows/macos-packetbeat.yml index d9e89368543..be5dc7377e6 100644 --- a/.github/workflows/macos-packetbeat.yml +++ b/.github/workflows/macos-packetbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-xpack-auditbeat.yml b/.github/workflows/macos-xpack-auditbeat.yml index 5da201dfa61..3adcb46f6da 100644 --- a/.github/workflows/macos-xpack-auditbeat.yml +++ b/.github/workflows/macos-xpack-auditbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-xpack-filebeat.yml b/.github/workflows/macos-xpack-filebeat.yml index ae7c0c4f35d..936c0913fa4 100644 --- a/.github/workflows/macos-xpack-filebeat.yml +++ b/.github/workflows/macos-xpack-filebeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-xpack-functionbeat.yml b/.github/workflows/macos-xpack-functionbeat.yml index d20c714a489..26a3e311c92 100644 --- a/.github/workflows/macos-xpack-functionbeat.yml +++ b/.github/workflows/macos-xpack-functionbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-xpack-heartbeat.yml b/.github/workflows/macos-xpack-heartbeat.yml index fcbc5e9b476..502d10c1a3e 100644 --- a/.github/workflows/macos-xpack-heartbeat.yml +++ b/.github/workflows/macos-xpack-heartbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-xpack-metricbeat.yml b/.github/workflows/macos-xpack-metricbeat.yml index 330bd1e48e4..38f40b051bc 100644 --- a/.github/workflows/macos-xpack-metricbeat.yml +++ b/.github/workflows/macos-xpack-metricbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-xpack-osquerybeat.yml b/.github/workflows/macos-xpack-osquerybeat.yml index af7a58dd8ab..1b3be3e3148 100644 --- a/.github/workflows/macos-xpack-osquerybeat.yml +++ b/.github/workflows/macos-xpack-osquerybeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9' diff --git a/.github/workflows/macos-xpack-packetbeat.yml b/.github/workflows/macos-xpack-packetbeat.yml index 163f6a9aaa8..90d9f77e269 100644 --- a/.github/workflows/macos-xpack-packetbeat.yml +++ b/.github/workflows/macos-xpack-packetbeat.yml @@ -18,11 +18,9 @@ jobs: runs-on: macos-latest steps: - uses: actions/checkout@v2 - - name: Fetch Go version from .go-version - run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV - uses: actions/setup-go@v3 with: - go-version: ${{ env.GO_VERSION }} + go-version-file: .go-version - uses: actions/setup-python@v4 with: python-version: '3.9'