From ea9f324e757cc352cc714aaa7c17084468abec12 Mon Sep 17 00:00:00 2001 From: Andrew Morgan Date: Wed, 13 May 2026 12:45:48 +0200 Subject: [PATCH] Use `--override` to set default toolchain And remove now unnecessary rustup default calls. --- .github/workflows/ci.yaml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 10891e4ad..828bec233 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -148,9 +148,10 @@ jobs: - name: Install Rust toolchain # Install the minimal toolchain, which includes rustc, rustdoc, and cargo. # Then install rustfmt for `cargo fmt`. + # + # --override sets this as the default rust toolchain version in this directory. run: | - rustup toolchain install nightly --profile minimal --component rustfmt - rustup default nightly + rustup toolchain install nightly --profile minimal --component rustfmt --override - name: Check style run: cargo fmt --all -- --check @@ -193,7 +194,6 @@ jobs: - name: Install Rust toolchain run: | rustup toolchain install stable - rustup default stable - name: Setup sccache uses: mozilla-actions/sccache-action@7d986dd989559c6ecdb630a3fd2557667be217ad # v0.0.9 @@ -235,7 +235,9 @@ jobs: - name: Install Rust toolchain # Install the minimal toolchain, which includes rustc, rustdoc, and cargo. - run: rustup toolchain install 1.93.0 --profile minimal --component clippy + # + # --override sets this as the default rust toolchain version in this directory. + run: rustup toolchain install 1.93.0 --profile minimal --component clippy --override - uses: ./.github/actions/build-policies