Skip to content

Commit 362d439

Browse files
committed
Enable clippy on CI
Add a clippy configuration file configuring the MSRV. Add a github actions job to run clippy on CI. Please note the job does _not_ use `--all-targets` because doing so causes: ``` error[E0554]: `#![feature]` may not be used on the stable release channel --> src/lib.rs:46:54 | 46 | #![cfg_attr(all(test, feature = "unstable"), feature(test))] ```
1 parent ad080cf commit 362d439

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

.github/workflows/rust.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,3 +107,18 @@ jobs:
107107
CARGO_TARGET_THUMBV7M_NONE_EABI_RUNNER: "qemu-system-arm -cpu cortex-m3 -machine mps2-an385 -nographic -semihosting-config enable=on,target=native -kernel"
108108
run: cd embedded && cargo run --target thumbv7m-none-eabi
109109

110+
Clippy:
111+
name: Clippy
112+
runs-on: ubuntu-latest
113+
steps:
114+
- uses: actions/checkout@v2
115+
- uses: actions-rs/toolchain@v1
116+
with:
117+
profile: minimal
118+
toolchain: stable
119+
override: true
120+
- run: rustup component add clippy
121+
- uses: actions-rs/cargo@v1
122+
with:
123+
command: clippy
124+
args: --all-features -- -D warnings

0 commit comments

Comments
 (0)