Skip to content
Snippets Groups Projects
Unverified Commit ec6430ba authored by David Robertson's avatar David Robertson Committed by GitHub
Browse files

Use setup-go instead of relying on go 1.17 to exist (#15403)

* Use setup-go instead of relying on 1.17 to exist

See https://github.com/actions/runner-images/issues/7276

* Changelog
parent 6eb3edec
No related branches found
No related tags found
No related merge requests found
...@@ -9,16 +9,6 @@ set -eu ...@@ -9,16 +9,6 @@ set -eu
alias block='{ set +x; } 2>/dev/null; func() { echo "::group::$*"; set -x; }; func' alias block='{ set +x; } 2>/dev/null; func() { echo "::group::$*"; set -x; }; func'
alias endblock='{ set +x; } 2>/dev/null; func() { echo "::endgroup::"; set -x; }; func' alias endblock='{ set +x; } 2>/dev/null; func() { echo "::endgroup::"; set -x; }; func'
block Set Go Version
# The path is set via a file given by $GITHUB_PATH. We need both Go 1.17 and GOPATH on the path to run Complement.
# See https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#adding-a-system-path
# Add Go 1.17 to the PATH: see https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-Readme.md#environment-variables-2
echo "$GOROOT_1_17_X64/bin" >> $GITHUB_PATH
# Add the Go path to the PATH: We need this so we can call gotestfmt
echo "~/go/bin" >> $GITHUB_PATH
endblock
block Install Complement Dependencies block Install Complement Dependencies
sudo apt-get -qq update && sudo apt-get install -qqy libolm3 libolm-dev sudo apt-get -qq update && sudo apt-get install -qqy libolm3 libolm-dev
go install -v github.com/gotesttools/gotestfmt/v2/cmd/gotestfmt@latest go install -v github.com/gotesttools/gotestfmt/v2/cmd/gotestfmt@latest
......
...@@ -184,6 +184,8 @@ jobs: ...@@ -184,6 +184,8 @@ jobs:
with: with:
path: synapse path: synapse
- uses: actions/setup-go@v4
- name: Prepare Complement's Prerequisites - name: Prepare Complement's Prerequisites
run: synapse/.ci/scripts/setup_complement_prerequisites.sh run: synapse/.ci/scripts/setup_complement_prerequisites.sh
......
...@@ -555,6 +555,8 @@ jobs: ...@@ -555,6 +555,8 @@ jobs:
toolchain: 1.58.1 toolchain: 1.58.1
- uses: Swatinem/rust-cache@v2 - uses: Swatinem/rust-cache@v2
- uses: actions/setup-go@v4
- name: Prepare Complement's Prerequisites - name: Prepare Complement's Prerequisites
run: synapse/.ci/scripts/setup_complement_prerequisites.sh run: synapse/.ci/scripts/setup_complement_prerequisites.sh
......
...@@ -147,6 +147,8 @@ jobs: ...@@ -147,6 +147,8 @@ jobs:
with: with:
path: synapse path: synapse
- uses: actions/setup-go@v4
- name: Prepare Complement's Prerequisites - name: Prepare Complement's Prerequisites
run: synapse/.ci/scripts/setup_complement_prerequisites.sh run: synapse/.ci/scripts/setup_complement_prerequisites.sh
......
Update CI to run complement under the latest stable go version.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment