File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ push :
5+ branches : [ main ]
6+ pull_request :
7+ branches : [ main ]
8+
9+ jobs :
10+ build-and-test :
11+ runs-on : ubuntu-latest
12+ strategy :
13+ matrix :
14+ toolchain : [ nightly ]
15+ steps :
16+ - name : Checkout
17+ uses : actions/checkout@v4
18+
19+ - name : Install Rust
20+ uses : dtolnay/rust-toolchain@master
21+ with :
22+ toolchain : ${{ matrix.toolchain }}
23+ components : rustfmt, clippy
24+
25+ - name : Show Rust version
26+ run : rustc -V && cargo -V
27+
28+ - name : Cache cargo registry
29+ uses : actions/cache@v4
30+ with :
31+ path : |
32+ ~/.cargo/registry
33+ ~/.cargo/git
34+ target
35+ key : ${{ runner.os }}-cargo-${{ matrix.toolchain }}-${{ hashFiles('**/Cargo.lock') }}
36+ restore-keys : |
37+ ${{ runner.os }}-cargo-${{ matrix.toolchain }}-
38+
39+ - name : Format check
40+ run : cargo fmt --all --check
41+
42+ - name : Clippy
43+ run : cargo clippy --all-targets -- -D warnings
You can’t perform that action at this time.
0 commit comments