2024-06-16 16:16:45 +02:00
|
|
|
name: ci
|
|
|
|
on: [push, pull_request]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
check:
|
|
|
|
name: Check build
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@stable
|
|
|
|
with:
|
|
|
|
targets: "thumbv6m-none-eabi"
|
2024-06-16 16:32:52 +02:00
|
|
|
- run: cargo check --target thumbv6m-none-eabi --release
|
|
|
|
- run: cargo check --target thumbv6m-none-eabi --examples --release
|
2024-06-16 16:16:45 +02:00
|
|
|
|
|
|
|
test:
|
|
|
|
name: Run Tests
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@stable
|
|
|
|
- name: Install nextest
|
|
|
|
uses: taiki-e/install-action@nextest
|
2024-06-16 16:32:52 +02:00
|
|
|
- run: cargo nextest run --all-features -p va108xx-hal
|
|
|
|
# I think we can skip those on an embedded crate..
|
|
|
|
# - run: cargo test --doc -p va108xx-hal
|
2024-06-16 16:16:45 +02:00
|
|
|
|
|
|
|
fmt:
|
|
|
|
name: Check formatting
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@stable
|
|
|
|
- run: cargo fmt --all -- --check
|
|
|
|
|
|
|
|
docs:
|
|
|
|
name: Check Documentation Build
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@nightly
|
|
|
|
- run: cargo +nightly doc --all-features --config 'build.rustdocflags=["--cfg", "docs_rs"]'
|
|
|
|
|
|
|
|
clippy:
|
|
|
|
name: Clippy
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@stable
|
2024-06-16 16:32:52 +02:00
|
|
|
with:
|
|
|
|
targets: "thumbv6m-none-eabi"
|
|
|
|
- run: cargo clippy --target thumbv6m-none-eabi -- -D warnings
|