-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (34 loc) · 952 Bytes
/
rust.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Rust
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
RUST_LOG: debug
jobs:
test:
name: Cargo Test
strategy: { matrix: { os: [ ubuntu-latest, macos-latest, windows-latest ] } }
runs-on: ${{ matrix.os }}
steps:
- name: Set git to not convert line endings
run: |
git config --global core.autocrlf false
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- uses: Swatinem/rust-cache@v2
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Show Compiler Version
run: rustc --version --verbose
- run: cargo fmt --check
- run: cargo clippy --all-targets --all-features -- -D warnings
- name: Test
run: cargo test --verbose
- name: Make sure clean can run
run: cargo run --features cli -- clean tests/examples -r