name: CI
on:
push:
branches:
- main
pull_request:
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: "true"
jobs:
fmt:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Install Rust
uses: dtolnay/rust-toolchain@b725eda525362e7cf34af9a7243cac1e3f01a7ec with:
components: rustfmt
- name: Check formatting
run: cargo fmt --all --check
clippy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Install Rust
uses: dtolnay/rust-toolchain@b725eda525362e7cf34af9a7243cac1e3f01a7ec with:
components: clippy
- name: Cache cargo
uses: Swatinem/rust-cache@d1527c8f67ef9af357290475d4af4b0fab8f12e0
- name: Run clippy
run: cargo clippy --locked --workspace --all-targets --all-features -- -D warnings
msrv:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Install Rust
uses: dtolnay/rust-toolchain@dc08e2af391d489dff6d14cf743e574f7d1229c5
- name: Cache cargo
uses: Swatinem/rust-cache@d1527c8f67ef9af357290475d4af4b0fab8f12e0
- name: Check against the declared MSRV
run: cargo check --locked --workspace --all-features
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Install Rust
uses: dtolnay/rust-toolchain@b725eda525362e7cf34af9a7243cac1e3f01a7ec
- name: Cache cargo
uses: Swatinem/rust-cache@d1527c8f67ef9af357290475d4af4b0fab8f12e0
- name: Test the builder and its derives
run: cargo test --locked --workspace --all-features