lints, MSRV, minimal crates #18
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
pull_request: | |
merge_group: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
env: | |
MSRV: "1.76" | |
RUST_BACKTRACE: "1" | |
RUSTFLAGS: "-Dwarnings" | |
RUSTDOCFLAGS: "-Dwarnings" | |
RUSTC_WRAPPER: "sccache" | |
SCCACHE_GHA_ENABLED: "true" | |
jobs: | |
lints: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
with: | |
components: rustfmt, clippy | |
- uses: mozilla-actions/[email protected] | |
- run: cargo fmt --check | |
- run: cargo clippy --no-deps | |
- run: cargo doc --no-deps --document-private-items | |
test: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest, windows-latest, macos-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: mozilla-actions/[email protected] | |
- uses: taiki-e/install-action@nextest | |
- run: cargo test | |
- run: cargo nextest run | |
minimal-crates: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@nightly | |
- uses: mozilla-actions/[email protected] | |
- name: cargo check | |
run: | | |
rm -f Cargo.lock | |
cargo +nightly check -Z minimal-versions | |
msrv: | |
runs-on: ubuntu-lates | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@master | |
with: | |
toolchain: ${{ env.MSRV }} | |
- uses: mozilla-actions/[email protected] | |
- name: Check MSRV | |
run: | | |
cargo +$MSRV check |