From 73ff31daf5d2c4b9d0f738ce5fe39aa5b59c6698 Mon Sep 17 00:00:00 2001 From: Marco Pasqualetti <24919330+marcalexiei@users.noreply.github.com> Date: Wed, 27 Nov 2024 20:40:00 +0100 Subject: [PATCH] ci(rust): avoid `beta` and `nightly` toolchains to be executed on macos and windows (#174) --- .github/workflows/rust.yml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 7f6c7bbd..d1462255 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -17,7 +17,7 @@ env: jobs: build_and_test: - name: Build and test rust crates + name: Build and test crates on ${{ matrix.os }} with rust ${{ matrix.toolchain }} strategy: fail-fast: true @@ -27,9 +27,15 @@ jobs: - 'macos-latest' - 'windows-latest' toolchain: - - stable - - beta - - nightly + - 'stable' + + # Test `beta` and `nightly` toolchains only on `ubuntu` + # https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/running-variations-of-jobs-in-a-workflow#expanding-or-adding-matrix-configurations + include: + - toolchain: 'beta' + os: 'ubuntu-latest' + - toolchain: 'nightly' + os: 'ubuntu-latest' runs-on: ${{ matrix.os }}