From 6c9be16e97bc18390e50f15f8156fcaeffd4abc7 Mon Sep 17 00:00:00 2001 From: Jiahao XU Date: Sun, 5 Nov 2023 09:19:21 +1000 Subject: [PATCH] Fix msrv CI: Check for `--all-features` (#890) * Fix msrv CI: Check for `--all-features` and macos To make sure that enabling `parallel` feature would not require bumping msrv. Signed-off-by: Jiahao XU * Use minimal-versions and fetch deps crates using stable Signed-off-by: Jiahao XU * Fix fetching deps in msrv Signed-off-by: Jiahao XU * Cache downlaoded crates since 1.46 is really slow in fetching Signed-off-by: Jiahao XU * Skip msrv for macos-latest since newer xcode breaks 1.46 linking Signed-off-by: Jiahao XU * CI: Disable fail-fast for msrv check Signed-off-by: Jiahao XU * CI: Add feature to cache key of msrv Signed-off-by: Jiahao XU * CI: Rm matrix features of msrv Since most of the time is spent on installing Rust, there's no point in parallelizing it. Signed-off-by: Jiahao XU --------- Signed-off-by: Jiahao XU --- .github/workflows/main.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 7aef82c15..4dff9b2d4 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -114,6 +114,7 @@ jobs: name: MSRV runs-on: ${{ matrix.os }} strategy: + fail-fast: false matrix: os: [ubuntu-latest, windows-latest] steps: @@ -121,9 +122,15 @@ jobs: - name: Install Rust run: | rustup toolchain install 1.46.0 --no-self-update --profile minimal + rustup toolchain install nightly --no-self-update --profile minimal rustup default 1.46.0 shell: bash + - name: Create Cargo.lock with minimal version + run: cargo +nightly update -Zminimal-versions + - name: Cache downloaded crates since 1.46 is really slow in fetching + uses: Swatinem/rust-cache@v2 - run: cargo check --lib + - run: cargo check --lib --all-features rustfmt: name: Rustfmt