Repository navigation
allow feature unification of rt on ch32-metapac dependency
#166
Workflow file for this run
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: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| env: | |
| CARGO_TERM_COLOR: always | |
| jobs: | |
| libs: | |
| name: Libraries | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: lib | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - run: rustup toolchain install stable --profile minimal --component rustfmt,clippy | |
| - run: cargo fmt --all -- --check | |
| - run: cargo clippy --all-targets -- -D warnings | |
| - run: cargo build | |
| - run: cargo test | |
| - run: cargo doc --no-deps | |
| - run: cargo build --release | |
| cli: | |
| name: CLI | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: cli | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - run: sudo apt-get update && sudo apt-get install -y libudev-dev | |
| - run: rustup toolchain install stable --profile minimal --component rustfmt,clippy | |
| - run: cargo fmt --all -- --check | |
| - run: cargo clippy -- -D warnings | |
| - run: cargo build | |
| - run: cargo build --release | |
| ch32-v003: | |
| name: CH32V003 (${{ matrix.chip }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| chip: [ch32v003f4p6, ch32v003a4m6, ch32v003f4u6, ch32v003j4m6] | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Install toolchain | |
| run: rustup toolchain install nightly --profile minimal --component rust-src,rustfmt,clippy | |
| - name: Fmt libraries | |
| run: cd ch32 && cargo +nightly fmt --all -- --check | |
| - name: Clippy libraries | |
| run: cd ch32 && cargo +nightly clippy --no-default-features --features ${{ matrix.chip }} --target ../examples/ch32/v003/riscv32ec-unknown-none-elf.json -Zbuild-std=core -Zjson-target-spec -- -D warnings | |
| - name: Build libraries | |
| run: cd ch32 && cargo +nightly build --no-default-features --features ${{ matrix.chip }} --target ../examples/ch32/v003/riscv32ec-unknown-none-elf.json -Zbuild-std=core -Zjson-target-spec --release | |
| - name: Doc libraries | |
| run: cd ch32 && cargo +nightly doc --no-default-features --features ${{ matrix.chip }} --target ../examples/ch32/v003/riscv32ec-unknown-none-elf.json -Zbuild-std=core -Zjson-target-spec --no-deps | |
| - name: Fmt examples | |
| run: cd examples/ch32/v003 && cargo +nightly fmt --all -- --check | |
| - name: Clippy boot (system-flash) | |
| run: cd examples/ch32/v003 && cargo +nightly clippy -p boot --no-default-features --features "${{ matrix.chip }},system-flash" -- -D warnings | |
| - name: Build boot (system-flash) | |
| run: cd examples/ch32/v003 && cargo +nightly build -p boot --no-default-features --features "${{ matrix.chip }},system-flash" --release | |
| - name: Clippy boot (user-flash) | |
| run: cd examples/ch32/v003 && cargo +nightly clippy -p boot --no-default-features --features "${{ matrix.chip }},user-flash" -- -D warnings | |
| - name: Build boot (user-flash) | |
| run: cd examples/ch32/v003 && cargo +nightly build -p boot --no-default-features --features "${{ matrix.chip }},user-flash" --release | |
| - name: Clippy app (system-flash) | |
| run: cd examples/ch32/v003 && cargo +nightly clippy -p app --no-default-features --features "${{ matrix.chip }},system-flash" -- -D warnings | |
| - name: Build app (system-flash) | |
| run: cd examples/ch32/v003 && cargo +nightly build -p app --no-default-features --features "${{ matrix.chip }},system-flash" --release | |
| - name: Clippy app (user-flash) | |
| run: cd examples/ch32/v003 && cargo +nightly clippy -p app --no-default-features --features "${{ matrix.chip }},user-flash" -- -D warnings | |
| - name: Build app (user-flash) | |
| run: cd examples/ch32/v003 && cargo +nightly build -p app --no-default-features --features "${{ matrix.chip }},user-flash" --release | |
| ch32-v103: | |
| name: CH32V103 (${{ matrix.chip }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| chip: [ch32v103c6t6, ch32v103c8t6, ch32v103c8u6, ch32v103r8t6] | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Install toolchain | |
| run: | | |
| rustup toolchain install stable --profile minimal --component rustfmt,clippy | |
| rustup target add riscv32imc-unknown-none-elf | |
| - name: Clippy libraries | |
| run: cd ch32 && cargo clippy --no-default-features --features ${{ matrix.chip }} --target riscv32imc-unknown-none-elf -- -D warnings | |
| - name: Build libraries | |
| run: cd ch32 && cargo build --no-default-features --features ${{ matrix.chip }} --target riscv32imc-unknown-none-elf --release | |
| - name: Fmt examples | |
| run: cd examples/ch32/v103 && cargo fmt --all -- --check | |
| - name: Clippy boot (system-flash) | |
| run: cd examples/ch32/v103 && cargo clippy -p boot --no-default-features --features "${{ matrix.chip }},system-flash" -- -D warnings | |
| - name: Build boot (system-flash) | |
| run: cd examples/ch32/v103 && cargo build -p boot --no-default-features --features "${{ matrix.chip }},system-flash" --release | |
| - name: Clippy boot (user-flash) | |
| run: cd examples/ch32/v103 && cargo clippy -p boot --no-default-features --features "${{ matrix.chip }},user-flash" -- -D warnings | |
| - name: Build boot (user-flash) | |
| run: cd examples/ch32/v103 && cargo build -p boot --no-default-features --features "${{ matrix.chip }},user-flash" --release | |
| - name: Clippy app (system-flash) | |
| run: cd examples/ch32/v103 && cargo clippy -p app --no-default-features --features "${{ matrix.chip }},system-flash" -- -D warnings | |
| - name: Build app (system-flash) | |
| run: cd examples/ch32/v103 && cargo build -p app --no-default-features --features "${{ matrix.chip }},system-flash" --release | |
| - name: Clippy app (user-flash) | |
| run: cd examples/ch32/v103 && cargo clippy -p app --no-default-features --features "${{ matrix.chip }},user-flash" -- -D warnings | |
| - name: Build app (user-flash) | |
| run: cd examples/ch32/v103 && cargo build -p app --no-default-features --features "${{ matrix.chip }},user-flash" --release |