-
Notifications
You must be signed in to change notification settings - Fork 18
43 lines (33 loc) · 1.2 KB
/
cargo-test.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
38
39
40
41
42
43
name: Cargo Checks
on: [push, pull_request]
jobs:
check:
name: Cargo Checks
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/[email protected]
with:
submodules: true
- name: Set up Python
uses: actions/[email protected]
with:
python-version: 3.8
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install ply six
- name: Run the generator
run: python generate.py
- name: Check generated files against repo
run: if [[ ! -z `git status --porcelain=v1` ]]; then echo "::error::Workspace is dirty after running generator. Did you remember to check in the generated files?"; exit 1; fi
- name: Install MSRV toolchain
run: rustup install 1.63.0 --profile minimal
- name: Run cargo test
run: rustup run 1.63.0 cargo test
- name: Install nightly toolchain
run: |
rustup install nightly --profile minimal
rustup component add clippy --toolchain nightly
- name: Run clippy
run: rustup run nightly cargo clippy --all-targets --all-features -- --deny warnings