Skip to content

Commit 2573d67

Browse files
Copilotnunoplopes
andcommitted
Add clippy checks to format workflow
Agent-Logs-Url: https://github.com/Cpp2Rust/cpp2rust/sessions/0d7756ba-9678-4a15-b2f9-5e6975d34282 Co-authored-by: Nuno Lopes <nuno.lopes@tecnico.ulisboa.pt>
1 parent 3eb91ca commit 2573d67

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

.github/workflows/format.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
uses: dtolnay/rust-toolchain@master
2222
with:
2323
toolchain: 1.95.0
24-
components: rustfmt
24+
components: rustfmt, clippy
2525

2626
- name: Check C++ formatting
2727
run: find cpp2rust tests -name '*.cpp' -o -name '*.h' -o -name '*.c' | xargs clang-format --dry-run --Werror
@@ -31,3 +31,10 @@ jobs:
3131
cargo fmt --manifest-path rules/Cargo.toml -- --check
3232
cargo fmt --manifest-path rule-preprocessor/Cargo.toml -- --check
3333
cargo fmt --manifest-path libcc2rs/Cargo.toml -- --check
34+
find tests -name '*.rs' -print0 | xargs -0 -r rustfmt --check
35+
36+
- name: Check Rust lints
37+
run: |
38+
cargo clippy --manifest-path rules/Cargo.toml --all-targets -- -D warnings
39+
cargo clippy --manifest-path rule-preprocessor/Cargo.toml --all-targets -- -D warnings
40+
cargo clippy --manifest-path libcc2rs/Cargo.toml --all-targets -- -D warnings

0 commit comments

Comments
 (0)