diff options
| author | Henrik Tjäder <henrik@tjaders.com> | 2023-02-06 13:35:05 +0100 |
|---|---|---|
| committer | Henrik Tjäder <henrik@tjaders.com> | 2023-03-01 00:35:16 +0100 |
| commit | 79b53ce82d1185b4ec995c42ce9ac56fb81c5274 (patch) | |
| tree | dad278088b81acd97ad572e0f8298249649fa175 | |
| parent | 0439867baf81b946159dcc49980b39f538ac2918 (diff) | |
CI: Use xtask for all checks
| -rw-r--r-- | .github/workflows/build.yml | 208 |
1 files changed, 12 insertions, 196 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ecbd7fa..f751b8c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -106,11 +106,19 @@ jobs: # Compilation check - checkrtic: + check: name: check rtic runs-on: ubuntu-22.04 strategy: matrix: + package: + - rtic + - rtic-arbiter + - rtic-channel + - rtic-common + - rtic-macros + - rtic-monotonics + - rtic-time target: - thumbv7m-none-eabi - thumbv6m-none-eabi @@ -122,208 +130,21 @@ jobs: uses: actions/checkout@v3 - name: Install Rust ${{ matrix.toolchain }} - working-directory: ./rtic - run: | - rustup set profile minimal - rustup override set ${{ matrix.toolchain }} - - - name: Configure Rust target (${{ matrix.target }}) - working-directory: ./rtic - run: rustup target add ${{ matrix.target }} - - - name: Fail on warnings - working-directory: ./rtic - run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs - - - name: Cache Dependencies - uses: Swatinem/rust-cache@v2 - - - name: cargo check - working-directory: ./rtic - run: cargo check --target=${{ matrix.target }} - - # Compilation check - checkrticmacros: - name: check rtic-macros - runs-on: ubuntu-22.04 - strategy: - matrix: - target: - - x86_64-unknown-linux-gnu - toolchain: - - nightly - steps: - - name: Checkout - uses: actions/checkout@v3 - - - name: Install Rust ${{ matrix.toolchain }} - working-directory: ./rtic-macros run: | rustup set profile minimal rustup override set ${{ matrix.toolchain }} - name: Configure Rust target (${{ matrix.target }}) - working-directory: ./rtic-macros run: rustup target add ${{ matrix.target }} - name: Fail on warnings - working-directory: ./rtic-macros - run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs + run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' ${{ matrix.package }}/src/lib.rs - name: Cache Dependencies uses: Swatinem/rust-cache@v2 - name: cargo check - working-directory: ./rtic-macros - run: cargo check --target=${{ matrix.target }} - - # Compilation check - checkarbiter: - name: check rtic-arbiter - runs-on: ubuntu-22.04 - strategy: - matrix: - target: - - thumbv7m-none-eabi - - thumbv6m-none-eabi - - x86_64-unknown-linux-gnu - toolchain: - - nightly - steps: - - name: Checkout - uses: actions/checkout@v3 - - - name: Install Rust ${{ matrix.toolchain }} - working-directory: ./rtic-arbiter - run: | - rustup set profile minimal - rustup override set ${{ matrix.toolchain }} - - - name: Configure Rust target (${{ matrix.target }}) - working-directory: ./rtic-arbiter - run: rustup target add ${{ matrix.target }} - - - name: Fail on warnings - working-directory: ./rtic-arbiter - run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs - - - name: Cache Dependencies - uses: Swatinem/rust-cache@v2 - - - name: cargo check - working-directory: ./rtic-arbiter - run: cargo check --target=${{ matrix.target }} - - # Compilation check - checkchannel: - name: check rtic-channel - runs-on: ubuntu-22.04 - strategy: - matrix: - target: - - thumbv7m-none-eabi - - thumbv6m-none-eabi - - x86_64-unknown-linux-gnu - toolchain: - - nightly - steps: - - name: Checkout - uses: actions/checkout@v3 - - - name: Install Rust ${{ matrix.toolchain }} - working-directory: ./rtic-channel - run: | - rustup set profile minimal - rustup override set ${{ matrix.toolchain }} - - - name: Configure Rust target (${{ matrix.target }}) - working-directory: ./rtic-channel - run: rustup target add ${{ matrix.target }} - - - name: Fail on warnings - working-directory: ./rtic-channel - run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs - - - name: Cache Dependencies - uses: Swatinem/rust-cache@v2 - - - name: cargo check - working-directory: ./rtic-channel - run: cargo check --target=${{ matrix.target }} - - # Compilation check - checkmonotonics: - name: check rtic-monotonics - runs-on: ubuntu-22.04 - strategy: - matrix: - target: - - thumbv7m-none-eabi - - thumbv6m-none-eabi - - x86_64-unknown-linux-gnu - toolchain: - - nightly - steps: - - name: Checkout - uses: actions/checkout@v3 - - - name: Install Rust ${{ matrix.toolchain }} - working-directory: ./rtic-monotonics - run: | - rustup set profile minimal - rustup override set ${{ matrix.toolchain }} - - - name: Configure Rust target (${{ matrix.target }}) - working-directory: ./rtic-monotonics - run: rustup target add ${{ matrix.target }} - - - name: Fail on warnings - working-directory: ./rtic-monotonics - run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs - - - name: Cache Dependencies - uses: Swatinem/rust-cache@v2 - - - name: cargo check - working-directory: ./rtic-monotonics - run: cargo check --target=${{ matrix.target }} - - # Compilation check - checktime: - name: check rtic-time - runs-on: ubuntu-22.04 - strategy: - matrix: - target: - - thumbv7m-none-eabi - - thumbv6m-none-eabi - - x86_64-unknown-linux-gnu - toolchain: - - nightly - steps: - - name: Checkout - uses: actions/checkout@v3 - - - name: Install Rust ${{ matrix.toolchain }} - working-directory: ./rtic-time - run: | - rustup set profile minimal - rustup override set ${{ matrix.toolchain }} - - - name: Configure Rust target (${{ matrix.target }}) - working-directory: ./rtic-time - run: rustup target add ${{ matrix.target }} - - - name: Fail on warnings - working-directory: ./rtic-time - run: sed -i 's,//deny_warnings_placeholder_for_ci,#![deny(warnings)],' src/lib.rs - - - name: Cache Dependencies - uses: Swatinem/rust-cache@v2 - - - name: cargo check - working-directory: ./rtic-time - run: cargo check --target=${{ matrix.target }} + run: cargo xtask --verbose --target=${{ matrix.target }} check ${{ matrix.package }} # Clippy clippyrtic: @@ -948,12 +769,7 @@ jobs: - stylechannel - stylemonotonics - styletime - - checkrtic - - checkrticmacros - - checkarbiter - - checkchannel - - checkmonotonics - - checktime + - check - clippyrtic - clippyrticmacros - clippyarbiter |
