| 1 |
name: Rust CI |
| 2 |
|
| 3 |
on: |
| 4 |
push: |
| 5 |
pull_request: |
| 6 |
|
| 7 |
jobs: |
| 8 |
build: |
| 9 |
name: Build & Lint |
| 10 |
runs-on: ubuntu-latest |
| 11 |
|
| 12 |
steps: |
| 13 |
- name: Checkout code |
| 14 |
uses: actions/checkout@v4 |
| 15 |
|
| 16 |
- name: Set up Rust |
| 17 |
uses: actions-rs/toolchain@v1 |
| 18 |
with: |
| 19 |
toolchain: stable |
| 20 |
profile: minimal |
| 21 |
components: clippy |
| 22 |
|
| 23 |
- name: Install cargo-binstall |
| 24 |
uses: cargo-bins/cargo-binstall@main |
| 25 |
|
| 26 |
- name: Run tests |
| 27 |
run: cargo test |
| 28 |
|
| 29 |
- name: Check (no_std) |
| 30 |
run: cargo check --no-default-features |
| 31 |
|
| 32 |
- name: Check (no_std, alloc) |
| 33 |
run: cargo check --no-default-features --features alloc |
| 34 |
|
| 35 |
- name: Run clippy |
| 36 |
run: cargo clippy |
| 37 |
|
| 38 |
- name: Install cargo-msrv |
| 39 |
run: cargo binstall --no-confirm cargo-msrv |
| 40 |
|
| 41 |
- name: Verify MSRV |
| 42 |
run: cargo msrv verify |