-
-
Notifications
You must be signed in to change notification settings - Fork 24
38 lines (38 loc) · 890 Bytes
/
lint.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
name: "Linting"
on:
push:
paths:
- '**/*.rs'
- '.github/workflows/*.yml'
pull_request:
paths:
- '**/*.rs'
- '.github/workflows/*.yml'
jobs:
lint:
name: "Linting"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: "Install stable Rust toolchain"
uses: actions-rs/toolchain@v1
with:
override: true
profile: minimal
toolchain: "stable"
components: rustfmt, clippy
- name: Run rustfmt
uses: actions-rs/cargo@v1
with:
args: "--all -- --check"
command: fmt
- name: Run 'cargo check'
uses: actions-rs/cargo@v1
with:
args: "--workspace"
command: check
- name: Run clippy
uses: actions-rs/cargo@v1
with:
args: "--workspace"
command: clippy