Skip to content

Commit

Permalink
Perform MSRV check via -Zminimal-versions (#2121)
Browse files Browse the repository at this point in the history
  • Loading branch information
MarijnS95 authored Jan 31, 2024
1 parent e2c835f commit 445970c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2,318 deletions.
19 changes: 13 additions & 6 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,16 +41,20 @@ jobs:
rust: ["1.61.0", nightly, beta]
steps:
- uses: actions/checkout@v4

- uses: dtolnay/rust-toolchain@nightly
if: ${{ matrix.rust == '1.61.0' }}
- name: Generate Cargo.lock with minimal-version dependencies
if: ${{ matrix.rust == '1.61.0' }}
run: cargo -Zminimal-versions generate-lockfile

- uses: dtolnay/rust-toolchain@v1
with:
toolchain: ${{ matrix.rust }}
- name: Cache Cargo Dependencies
uses: Swatinem/rust-cache@v2
with:
cache-on-failure: true
- name: Install MSRV Cargo.lock
if: ${{ matrix.rust == '1.61.0' }}
run: mv Cargo.lock.msrv Cargo.lock
- name: build
run: cargo build -v --features webp,webp-encoder
- name: test
Expand Down Expand Up @@ -202,7 +206,10 @@ jobs:
uses: baptiste0928/cargo-install@v2
with:
crate: cargo-msrv
- name: Install MSRV Cargo.lock
run: mv Cargo.lock.msrv Cargo.lock
- name: Verify Minimum Rust Version

- uses: dtolnay/rust-toolchain@nightly
- name: Generate Cargo.lock with minimal-version dependencies
run: cargo -Zminimal-versions generate-lockfile

- name: Verify Minimum Rust Version against `-Zminimal-versions` dependencies
run: cargo-msrv verify
Loading

0 comments on commit 445970c

Please sign in to comment.