ci: fix tooling install command #2
This file contains hidden or 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: Continuous Integration | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
jobs: | |
test-latest: | |
name: Test on latest Rust | |
runs-on: ubuntu-latest | |
steps: | |
- name: "Rust Version" | |
run: rustc --version | |
- name: "Checkout code" | |
uses: actions/checkout@v4 | |
- name: Setup | |
run: | | |
rustc --version | |
sudo apt-get update && apt-get install -y valgrind | |
cargo install cargo-valgrind | |
- name: Run tests | |
run: | | |
cargo valgrind test | |
cargo test | |
- name: Upload artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: target-latest | |
path: target | |
retention-days: 14 | |
test-msrv: | |
name: Test on Rust MSRV (1.63.0) | |
runs-on: ubuntu-latest | |
container: | |
image: rust:1.63.0 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup | |
run: | | |
rustc --version | |
apt-get update && apt-get install -y valgrind | |
cargo install cargo-valgrind --version 2.0.0 | |
- name: Run tests | |
run: | | |
cargo valgrind test | |
cargo test | |
- name: Upload artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: target-msrv | |
path: target | |
retention-days: 14 | |
Format: | |
name: Format - nightly toolchain | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
steps: | |
- name: "Checkout repo" | |
uses: actions/checkout@v4 | |
- name: "Select toolchain" | |
uses: dtolnay/rust-toolchain@nightly | |
- name: "Install rustfmt" | |
run: rustup component add rustfmt | |
- name: "Check formatting" | |
run: cargo +nightly fmt --all -- --check |