Skip to content

Commit be2b623

Browse files
authored
Merge pull request #26 from rust-embedded-community/add-clippy
Add clippy
2 parents 05f0382 + 09c83b6 commit be2b623

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

.github/workflows/rust.yml

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,36 @@ name: Rust
22

33
on: [push, pull_request]
44

5+
# Make sure CI fails on all warnings, including Clippy lints
6+
env:
7+
RUSTFLAGS: "-Dwarnings"
8+
59
jobs:
610
formatting:
711
runs-on: ubuntu-latest
812
steps:
9-
- uses: actions/checkout@v1
13+
- uses: actions/checkout@v4
1014
- name: Check formatting
1115
run: cargo fmt -- --check
1216

1317
build-test:
1418
runs-on: ubuntu-latest
1519
steps:
16-
- uses: actions/checkout@v1
20+
- uses: actions/checkout@v4
1721
- name: Build
1822
run: cargo build
1923
- name: Run Tests
2024
run: cargo test
25+
26+
clippy:
27+
runs-on: ubuntu-latest
28+
steps:
29+
- uses: actions/checkout@v4
30+
- name: Clippy (default features)
31+
run: cargo clippy
32+
- name: Clippy (no features)
33+
run: cargo clippy --no-default-features
34+
- name: Clippy (all features)
35+
run: cargo clippy --all-features
36+
37+

0 commit comments

Comments
 (0)