-
Notifications
You must be signed in to change notification settings - Fork 9
163 lines (134 loc) · 3.89 KB
/
Copy pathrust-pr-quality.yml
File metadata and controls
163 lines (134 loc) · 3.89 KB
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
name: Rust PR Quality Control
on:
pull_request:
branches: ["rust-next", "main"]
workflow_dispatch:
permissions:
contents: read
concurrency:
group: rust-pr-quality-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
jobs:
fmt:
name: Format
runs-on: ubuntu-latest
steps:
- name: Check out RCH
uses: actions/checkout@v6
with:
path: rch
- name: Check out LXMF-rs
uses: actions/checkout@v6
with:
repository: FreeTAKTeam/LXMF-rs
path: LXMF-rs
ref: ed4a8a1e7921925023ed5583d20f75c7671e3b6e
- name: Install Rust 1.88
uses: dtolnay/rust-toolchain@stable
with:
toolchain: "1.88"
components: rustfmt
- name: Check Rust formatting
working-directory: rch
run: cargo fmt --all -- --check
clippy:
name: Clippy
runs-on: ubuntu-latest
steps:
- name: Check out RCH
uses: actions/checkout@v6
with:
path: rch
- name: Check out LXMF-rs
uses: actions/checkout@v6
with:
repository: FreeTAKTeam/LXMF-rs
path: LXMF-rs
ref: ed4a8a1e7921925023ed5583d20f75c7671e3b6e
- name: Install Rust 1.88
uses: dtolnay/rust-toolchain@stable
with:
toolchain: "1.88"
components: clippy
- name: Check locked dependencies
working-directory: rch
run: cargo fetch --locked
- name: Run clippy
working-directory: rch
run: cargo clippy --workspace --all-targets -- -D warnings
tests:
name: Workspace Tests
runs-on: ubuntu-latest
steps:
- name: Check out RCH
uses: actions/checkout@v6
with:
path: rch
- name: Check out LXMF-rs
uses: actions/checkout@v6
with:
repository: FreeTAKTeam/LXMF-rs
path: LXMF-rs
ref: ed4a8a1e7921925023ed5583d20f75c7671e3b6e
- name: Install Rust 1.88
uses: dtolnay/rust-toolchain@stable
with:
toolchain: "1.88"
- name: Check locked dependencies
working-directory: rch
run: cargo fetch --locked
- name: Run workspace tests
working-directory: rch
run: cargo test --workspace -- --test-threads=1
release-builds:
name: Release Builds
runs-on: ubuntu-latest
steps:
- name: Check out RCH
uses: actions/checkout@v6
with:
path: rch
- name: Check out LXMF-rs
uses: actions/checkout@v6
with:
repository: FreeTAKTeam/LXMF-rs
path: LXMF-rs
ref: ed4a8a1e7921925023ed5583d20f75c7671e3b6e
- name: Install Rust 1.88
uses: dtolnay/rust-toolchain@stable
with:
toolchain: "1.88"
- name: Check locked dependencies
working-directory: rch
run: cargo fetch --locked
- name: Build server release binary
working-directory: rch
run: cargo build --release -p r3akt-rch-server
- name: Build TAK service release binary
working-directory: rch
run: cargo build --release -p r3akt-tak-connector --bin r3akt-tak-service
dependency-audit:
name: Dependency Audit
runs-on: ubuntu-latest
steps:
- name: Check out RCH
uses: actions/checkout@v6
with:
path: rch
- name: Check out LXMF-rs
uses: actions/checkout@v6
with:
repository: FreeTAKTeam/LXMF-rs
path: LXMF-rs
ref: ed4a8a1e7921925023ed5583d20f75c7671e3b6e
- name: Install Rust 1.88
uses: dtolnay/rust-toolchain@stable
with:
toolchain: "1.88"
- name: Install cargo-audit
uses: taiki-e/install-action@cargo-audit
- name: Audit locked dependency graph
working-directory: rch
run: cargo audit --deny warnings