2022-08-16 01:26:39 +02:00
|
|
|
name: ci
|
2024-05-02 14:12:26 +02:00
|
|
|
on: [push, pull_request]
|
2022-08-16 01:26:39 +02:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
check:
|
2024-05-02 14:12:26 +02:00
|
|
|
name: Check build
|
2022-08-16 11:03:51 +02:00
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
|
|
runs-on: ${{ matrix.os }}
|
2022-08-16 10:11:49 +02:00
|
|
|
steps:
|
2024-05-02 14:12:26 +02:00
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@stable
|
|
|
|
- run: cargo check --release
|
|
|
|
|
|
|
|
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
|
2024-05-02 14:48:31 +02:00
|
|
|
- run: cargo test --doc
|
2022-08-16 10:11:49 +02:00
|
|
|
|
2023-01-11 00:02:37 +01:00
|
|
|
msrv:
|
2024-05-02 14:12:26 +02:00
|
|
|
name: Check MSRV
|
2023-01-11 00:02:37 +01:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2024-05-02 14:12:26 +02:00
|
|
|
- uses: actions/checkout@v4
|
2024-05-19 09:12:39 +02:00
|
|
|
- uses: dtolnay/rust-toolchain@1.68.2
|
2024-05-02 14:12:26 +02:00
|
|
|
- run: cargo check --release
|
2023-01-11 00:02:37 +01:00
|
|
|
|
2022-08-16 10:11:49 +02:00
|
|
|
cross-check:
|
2024-05-02 14:12:26 +02:00
|
|
|
name: Check Cross-Compilation
|
2022-08-16 01:26:39 +02:00
|
|
|
runs-on: ubuntu-latest
|
2024-05-02 14:22:03 +02:00
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
target:
|
|
|
|
- armv7-unknown-linux-gnueabihf
|
|
|
|
- thumbv7em-none-eabihf
|
2022-08-16 01:26:39 +02:00
|
|
|
steps:
|
2024-05-02 14:12:26 +02:00
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@stable
|
2024-05-02 14:16:20 +02:00
|
|
|
with:
|
|
|
|
targets: "armv7-unknown-linux-gnueabihf, thumbv7em-none-eabihf"
|
2024-05-02 14:22:03 +02:00
|
|
|
- run: cargo check --release --target=${{matrix.target}} --no-default-features
|
2022-08-16 01:26:39 +02:00
|
|
|
|
|
|
|
fmt:
|
2024-05-02 14:12:26 +02:00
|
|
|
name: Check formatting
|
2022-08-16 01:26:39 +02:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2024-05-02 14:12:26 +02:00
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@stable
|
|
|
|
- run: cargo fmt --all -- --check
|
2022-08-16 01:26:39 +02:00
|
|
|
|
2024-05-02 14:12:26 +02:00
|
|
|
docs:
|
2023-01-11 00:14:23 +01:00
|
|
|
name: Check Documentation Build
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2024-05-02 14:12:26 +02:00
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: dtolnay/rust-toolchain@nightly
|
2024-06-25 16:07:07 +02:00
|
|
|
- run: RUSTDOCFLAGS="--cfg docsrs --generate-link-to-definition -Z unstable-options" cargo +nightly doc --all-features
|
2023-01-11 00:14:23 +01:00
|
|
|
|
2022-08-16 01:26:39 +02:00
|
|
|
clippy:
|
|
|
|
name: Clippy
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2024-05-02 14:12:26 +02:00
|
|
|
- uses: actions/checkout@v4
|
2024-05-02 14:16:20 +02:00
|
|
|
- uses: dtolnay/rust-toolchain@stable
|
2024-05-02 14:12:26 +02:00
|
|
|
- run: cargo clippy -- -D warnings
|