Skip to content

Commit cb85fc7

Browse files
committed
add clippy and formatting to ci
1 parent a43de9c commit cb85fc7

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

.github/workflows/ci.yml

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,28 @@
11
name: Continuous integration
22
on: [push, pull_request]
33

4+
env:
5+
RUSTFLAGS: "-Dwarnings"
6+
RUSTDOCFLAGS: "-Dwarnings"
7+
48
jobs:
5-
ci:
9+
test:
610
runs-on: ubuntu-latest
711
steps:
8-
- uses: actions/checkout@v3
12+
- uses: actions/checkout@v4
913
- uses: dtolnay/rust-toolchain@stable
1014
- run: cargo build
1115
- run: cargo test
16+
17+
checks:
18+
name: Check clippy, formatting, and documentation
19+
runs-on: ubuntu-latest
20+
steps:
21+
- uses: actions/checkout@v4
22+
- uses: dtolnay/rust-toolchain@1.81.0
23+
with:
24+
components: clippy, rustfmt
25+
- uses: Swatinem/rust-cache@v2
26+
- run: cargo clippy --workspace --all-targets --all-features
27+
- run: cargo fmt --check --all
28+
- run: cargo doc --workspace --no-deps

0 commit comments

Comments
 (0)