ci: Update Github CI to use new dtolynay/rust-toolchain and nextest (#2) #5
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: Pull Request Validation | |
on: | |
push: | |
branches: ["main"] | |
paths-ignore: | |
- "README.md" | |
- "Dockerfile" | |
pull_request: | |
branches: ["main"] | |
paths-ignore: | |
- "README.md" | |
- "Dockerfile" | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
lfs: true | |
- name: Install Rust toolchain | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
components: clippy,rustfmt | |
- name: Install cargo nextest | |
uses: taiki-e/install-action@cargo-nextest | |
- name: Check formatting | |
run: cargo fmt --all --check | |
- name: Lint with clippy | |
run: cargo clippy --all-targets -- -D warnings | |
- name: Run tests | |
run: cargo nextest --verbose run | |
- name: Build | |
run: cargo build --release |