Skip to content

Commit

Permalink
ci: Use cargo-hack's --rust-version flag for msrv check
Browse files Browse the repository at this point in the history
This respects rust-version field in Cargo.toml, so it removes the need
to manage MSRV in both the CI file and Cargo.toml.
  • Loading branch information
taiki-e committed Jan 6, 2024
1 parent 08c7e16 commit 45272f9
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,17 +66,12 @@ jobs:

msrv:
runs-on: ubuntu-latest
strategy:
matrix:
# When updating this, the reminder to update the minimum supported
# Rust version in Cargo.toml.
rust: ['1.61']
steps:
- uses: actions/checkout@v4
- name: Install Rust
run: rustup update ${{ matrix.rust }} && rustup default ${{ matrix.rust }}
- run: cargo build --all
- run: cargo build --all --no-default-features
- name: Install cargo-hack
uses: taiki-e/install-action@cargo-hack
- run: cargo hack build --all --rust-version
- run: cargo hack build --all --no-default-features --rust-version

clippy:
runs-on: ubuntu-latest
Expand Down

0 comments on commit 45272f9

Please sign in to comment.