name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
test:
name: fmt, clippy, test (${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Checkout
uses: actions/checkout@v7
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
components: clippy, rustfmt
- name: Cargo fmt
run: cargo fmt -- --check
- name: Cargo clippy
run: cargo clippy --all-targets --all-features -- -D warnings
- name: Cargo test
run: cargo test
- name: Cargo check (no default features)
run: cargo check --no-default-features --features graveyard
- name: Release build
run: cargo build --release
msrv:
name: MSRV build + test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v7
- name: Install pinned MSRV toolchain
uses: dtolnay/rust-toolchain@1.95
- name: Cargo build (MSRV)
run: cargo build --all-targets --all-features
- name: Cargo test (MSRV)
run: cargo test