@@ -50,13 +50,50 @@ runs:
5050
5151 - name : Install Rust toolchain
5252 if : ${{ inputs.needs_rust == 'true' }}
53- uses : dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
54- with :
55- toolchain : stable
53+ shell : bash
54+ run : |
55+ set -euo pipefail
56+
57+ case "${{ inputs.platform }}-${{ inputs.arch }}" in
58+ linux-amd64)
59+ target="x86_64-unknown-linux-gnu"
60+ ;;
61+ macos-aarch64)
62+ target="aarch64-apple-darwin"
63+ ;;
64+ *)
65+ echo "Unsupported Rust toolchain platform/arch: ${{ inputs.platform }}/${{ inputs.arch }}" >&2
66+ exit 1
67+ ;;
68+ esac
69+
70+ tmpdir="$(mktemp -d)"
71+ trap 'rm -rf "$tmpdir"' EXIT
72+
73+ curl -fsSLo "$tmpdir/rustup-init" \
74+ "https://static.rust-lang.org/rustup/dist/${target}/rustup-init"
75+ curl -fsSLo "$tmpdir/rustup-init.sha256" \
76+ "https://static.rust-lang.org/rustup/dist/${target}/rustup-init.sha256"
77+
78+ if command -v sha256sum >/dev/null 2>&1; then
79+ (cd "$tmpdir" && sha256sum -c rustup-init.sha256)
80+ else
81+ (cd "$tmpdir" && shasum -a 256 -c rustup-init.sha256)
82+ fi
83+
84+ chmod +x "$tmpdir/rustup-init"
85+ "$tmpdir/rustup-init" -y --profile minimal --default-toolchain stable
86+ echo "${HOME}/.cargo/bin" >> "$GITHUB_PATH"
5687
5788 - name : Install uv
5889 if : ${{ inputs.needs_uv == 'true' }}
59- uses : astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
90+ shell : bash
91+ run : |
92+ set -euo pipefail
93+
94+ python3 -m venv "$RUNNER_TEMP/uv-venv"
95+ "$RUNNER_TEMP/uv-venv/bin/python" -m pip install "uv==0.11.21"
96+ echo "$RUNNER_TEMP/uv-venv/bin" >> "$GITHUB_PATH"
6097
6198 - name : Get GraalPy CE dev build
6299 if : ${{ inputs.platform == 'macos' }}
0 commit comments