-
Notifications
You must be signed in to change notification settings - Fork 4
77 lines (70 loc) · 1.88 KB
/
tacd-daemon.yaml
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
name: tacd
on:
pull_request:
paths-ignore:
- 'web/**'
push:
branches:
- main
schedule:
- cron: '48 20 * * 4'
env:
# Make sure cargo commands not only fail on hard errors but also on warnings
# so we do not accidentally miss newly introduced warnings.
RUSTFLAGS: -D warnings
jobs:
fmt:
name: cargo fmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: rustup toolchain install stable
- run: cargo fmt --all -- --check
clippy:
strategy:
matrix:
features:
- ""
- "--features=demo_mode --no-default-features"
- "--tests"
name: cargo clippy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sudo apt update
- run: sudo apt install libsystemd-dev libiio-dev
- run: rustup toolchain install stable
- run: cargo clippy ${{ matrix.features }}
check:
strategy:
fail-fast: false # Run against all versions even if one fails
matrix:
version:
- "1.75" # Yocto scarthgap
- "1.79" # Yocto styhead
- "nightly"
name: cargo check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sudo apt update
- run: sudo apt install libsystemd-dev libiio-dev
- run: rustup toolchain install ${{ matrix.version }}
- run: rustup run ${{ matrix.version }} cargo check
deny:
name: cargo deny
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: rustup toolchain install stable
- run: cargo install --locked cargo-deny
- run: cargo deny check
test:
name: cargo test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sudo apt update
- run: sudo apt install libsystemd-dev libiio-dev
- run: rustup toolchain install stable
- run: cargo test