-
Notifications
You must be signed in to change notification settings - Fork 47
56 lines (47 loc) · 1.32 KB
/
check-clippy.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
44
45
46
47
48
49
50
51
52
53
54
55
56
name: Clippy-checks
on:
pull_request:
push:
branches:
- develop
- master
- 'refs/tags/[0-9]+.[0-9]+.[0-9]+*'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
RUSTDOCFLAGS: '-D warnings'
jobs:
clippy:
name: Run Clippy with different features combinations
runs-on: ubuntu-latest
strategy:
matrix:
features:
-
- --all-features
steps:
- name: Download repository
uses: actions/checkout@v4
- name: Set up Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Set up cargo cache
uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ github.job }}-${{ github.ref }}-${{ matrix.features }}-cargo-cache
- name: Run Test
run: |
docker run --rm \
-v "${GITHUB_WORKSPACE}:/workspace" \
-v "${HOME}/.cargo:/root/.cargo" \
-w /workspace \
-e RUSTDOCFLAGS='-D warnings' \
-e SKIP_WASM_BUILD=1 \
paritytech/ci-unified:bullseye-1.74.0 \
bash -c "cargo clippy --locked --quiet ${{ matrix.features }}"