73 lines
1.8 KiB
YAML
73 lines
1.8 KiB
YAML
name: ci
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
name: Check build
|
|
strategy:
|
|
matrix:
|
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
runs-on: ${{ matrix.os }}
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: dtolnay/rust-toolchain@stable
|
|
- run: cargo check --release
|
|
|
|
cross-check:
|
|
name: Check Cross-Compilation
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
target:
|
|
- armv7-unknown-linux-gnueabihf
|
|
- thumbv7em-none-eabihf
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: dtolnay/rust-toolchain@stable
|
|
with:
|
|
targets: "armv7-unknown-linux-gnueabihf, thumbv7em-none-eabihf"
|
|
- run: cargo check --release --target=${{matrix.target}} --no-default-features
|
|
|
|
check:
|
|
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
|
|
- run: cargo nextest run --all-features
|
|
- run: cargo test --doc
|
|
|
|
msrv:
|
|
name: Check MSRV
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: dtolnay/rust-toolchain@1.68.2
|
|
- run: cargo check --release
|
|
|
|
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
|
|
- run: cargo clippy -- -D warnings
|