Skip to content

Commit

Permalink
CI: Replace unnecessary actions-rs steps with direct `run: cargo ..…
Browse files Browse the repository at this point in the history
….` (#63)

GitHub Actions' `runner-images` already come fully loaded with all the
Rust tools that we need [1]: remove the bloated and outdated
`actions-rs/toolchain` setup step for that, and also remove the
`actions-rs/cargo` action that only serves as a more convoluted way to
run simple `cargo` shell commands.

[1]: https://github.com/actions/runner-images/blob/main/images/linux/Ubuntu2204-Readme.md#rust-tools
  • Loading branch information
MarijnS95 authored Mar 27, 2023
1 parent ddcdfc6 commit 0a7de58
Showing 1 changed file with 3 additions and 18 deletions.
21 changes: 3 additions & 18 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,24 +22,9 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
profile: minimal
override: true
components: rustfmt, clippy
- name: Cargo check
uses: actions-rs/cargo@v1
with:
command: check
args: --workspace --all-targets
run: cargo check --workspace --all-targets
- name: Cargo fmt
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
run: cargo fmt --all -- --check
- name: Cargo clippy
uses: actions-rs/cargo@v1
with:
command: clippy
args: --workspace --all-targets -- -D warnings
run: cargo clippy --workspace --all-targets -- -D warnings

0 comments on commit 0a7de58

Please sign in to comment.