# Formatting, lints and every test, on each pull request and each push to main.
name: ci
on:
pull_request:
push:
branches:
permissions:
contents: read
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
# rustup installs the channel rust-toolchain.toml names on first use.
- run: rustup show active-toolchain || rustup toolchain install
- run: cargo fmt --check
- run: cargo clippy --all-targets --locked -- -D warnings
- run: cargo test --release --locked