Use a simpler action for builds
- Id
- 16aa9f68ca60601e593c857303ce34d809a86eb7
- Author
- Caio
- Commit time
- 2023-07-05T08:31:44+02:00
Modified .github/workflows/ci.yml
name: Testsuite with default (zero) features
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
- - uses: actions-rs/toolchain@v1
- with:
- profile: minimal
- toolchain: stable
- override: true
- - uses: actions-rs/cargo@v1
- with:
- command: test
+ - uses: actions/checkout@v3
+ - uses: dtolnay/rust-toolchain@stable
+ - run: cargo test
test:
name: Testsuite with all features
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
- - uses: actions-rs/toolchain@v1
- with:
- profile: minimal
- toolchain: stable
- override: true
- - uses: actions-rs/cargo@v1
- with:
- command: test
- args: --all-features
+ - uses: actions/checkout@v3
+ - uses: dtolnay/rust-toolchain@stable
+ - run: cargo test --all-features
fmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
- - uses: actions-rs/toolchain@v1
+ - uses: actions/checkout@v3
+ - uses: dtolnay/rust-toolchain@stable
with:
- profile: minimal
- toolchain: stable
- override: true
- - run: rustup component add rustfmt
- - uses: actions-rs/cargo@v1
- with:
- command: fmt
- args: --all -- --check
+ components: rustfmt
+ - run: cargo fmt --all -- --check
cortex_m_build:
name: No-std compat (x-build)
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
- - uses: actions-rs/toolchain@v1
+ - uses: actions/checkout@v3
+ - uses: dtolnay/rust-toolchain@stable
with:
- profile: minimal
- toolchain: stable
- override: true
- target: thumbv7m-none-eabi
+ targets: thumbv7m-none-eabi
- name: Check default (zero) features
- uses: actions-rs/cargo@v1
- with:
- command: check
- args: --target thumbv7m-none-eabi
+ run: cargo check --target thumbv7m-none-eabi
- name: Check tracing feature
- uses: actions-rs/cargo@v1
- with:
- command: check
- args: --target thumbv7m-none-eabi --features tracing
+ run: cargo check --target thumbv7m-none-eabi --features tracing
- name: Check postcard-codec feature
- uses: actions-rs/cargo@v1
- with:
- command: check
- args: --target thumbv7m-none-eabi --features postcard-codec
+ run: cargo check --target thumbv7m-none-eabi --features postcard-codec
- name: Check every no-std feature
- uses: actions-rs/cargo@v1
- with:
- command: check
- args: --target thumbv7m-none-eabi --features tracing,postcard-codec
+ run: cargo check --target thumbv7m-none-eabi --features tracing,postcard-codec
clippy:
name: Clippy
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
- - uses: actions-rs/toolchain@v1
+ - uses: actions/checkout@v3
+ - uses: dtolnay/rust-toolchain@stable
with:
- profile: minimal
- toolchain: stable
- override: true
- - run: rustup component add clippy
- - uses: actions-rs/cargo@v1
- with:
- command: clippy
- args: --all-features -- -D warnings
+ components: clippy
+ - run: cargo clippy --all-features -- -D warnings
features:
name: Features Powerset Tests
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
- - uses: actions-rs/toolchain@v1
- with:
- profile: minimal
- toolchain: stable
- override: true
+ - uses: actions/checkout@v3
+ - uses: dtolnay/rust-toolchain@stable
- name: Install cargo-hack
run: cargo install cargo-hack
- name: Run checks