-
Notifications
You must be signed in to change notification settings - Fork 58
56 lines (45 loc) · 1.22 KB
/
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
on:
pull_request:
push:
branches:
- main
name: CI
jobs:
ci:
name: CI
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Update Packages
run: sudo apt-get update -yq --allow-releaseinfo-change
- name: Install dependencies
run: sudo apt-get install -yq --no-install-recommends libudev-dev libasound2-dev libxcb-composite0-dev
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- name: Cache Dependencies
uses: Swatinem/rust-cache@ce325b60658c1b38465c06cc965b79baf32c1e72
- name: Install fmt
run: rustup component add rustfmt
- name: fmt
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- name: check
uses: actions-rs/cargo@v1
with:
command: check
- name: Install clippy
run: rustup component add clippy
- name: run clippy
uses: actions-rs/cargo@v1
with:
command: clippy
args: -- -D warnings
- name: test
uses: actions-rs/cargo@v1
with:
command: test