-
Notifications
You must be signed in to change notification settings - Fork 174
229 lines (220 loc) · 8.19 KB
/
dist.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
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
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
name: dist
on:
pull_request:
push:
branches: [master]
jobs:
build:
name: dist
runs-on: '${{ matrix.os }}'
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
build: [stm32f3, stm32f4, lpc55, stm32h743, stm32h753, gemini, rot-carrier, gimletlet, gimlet-b, gimlet-b-lab, gimlet-b-dev, gimlet-c, gimlet-c-lab, gimlet-c-dev, gimlet-d, gimlet-d-lab, gimlet-d-dev, sidecar-b, sidecar-b-lab, sidecar-b-dev, sidecar-c, sidecar-c-lab, sidecar-c-dev, psc-b, psc-b-dev, psc-c, psc-c-dev, stm32g0, oxide-rot-1, oxide-rot-1-dev, donglet-g031]
include:
- build: stm32g0
app_name: demo-stm32g070-nucleo
app_toml: app/demo-stm32g0-nucleo/app-g070.toml
target: thumbv6m-none-eabi
image: default
- build: stm32f3
app_name: demo-stm32f3-discovery
app_toml: app/demo-stm32f4-discovery/app-f3.toml
target: thumbv7em-none-eabihf
image: default
- build: stm32f4
app_name: demo-stm32f4-discovery
app_toml: app/demo-stm32f4-discovery/app.toml
target: thumbv7em-none-eabihf
image: default
- build: lpc55
app_name: lpc55xpresso
app_toml: app/lpc55xpresso/app.toml
target: thumbv8m.main-none-eabihf
image: [a, b]
- build: stm32h743
app_name: demo-stm32h743-nucleo
app_toml: app/demo-stm32h7-nucleo/app-h743.toml
target: thumbv7em-none-eabihf
image: default
- build: stm32h753
app_name: demo-stm32h753-nucleo
app_toml: app/demo-stm32h7-nucleo/app-h753.toml
target: thumbv7em-none-eabihf
image: default
- build: gemini
app_name: gemini-bu
app_toml: app/gemini-bu/app.toml
target: thumbv7em-none-eabihf
image: default
- build: rot-carrier
app_name: rot-carrier
app_toml: app/rot-carrier/app.toml
target: thumbv8m.main-none-eabihf
image: [a, b]
- build: gimletlet
app_name: gimletlet
app_toml: app/gimletlet/app.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-b
app_name: gimlet-b
app_toml: app/gimlet/rev-b.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-b-lab
app_name: gimlet-b-lab
app_toml: app/gimlet/rev-b-lab.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-b-dev
app_name: gimlet-b-dev
app_toml: app/gimlet/rev-b-dev.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-c
app_name: gimlet-c
app_toml: app/gimlet/rev-c.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-c-lab
app_name: gimlet-c-lab
app_toml: app/gimlet/rev-c-lab.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-c-dev
app_name: gimlet-c-dev
app_toml: app/gimlet/rev-c-dev.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-d
app_name: gimlet-d
app_toml: app/gimlet/rev-d.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-d-lab
app_name: gimlet-d-lab
app_toml: app/gimlet/rev-d-lab.toml
target: thumbv7em-none-eabihf
image: default
- build: gimlet-d-dev
app_name: gimlet-d-dev
app_toml: app/gimlet/rev-d-dev.toml
target: thumbv7em-none-eabihf
image: default
- build: sidecar-b
app_name: sidecar-b
app_toml: app/sidecar/rev-b.toml
target: thumbv7em-none-eabihf
image: default
- build: sidecar-b-lab
app_name: sidecar-b-lab
app_toml: app/sidecar/rev-b-lab.toml
target: thumbv7em-none-eabihf
image: default
- build: sidecar-b-dev
app_name: sidecar-b-dev
app_toml: app/sidecar/rev-b-dev.toml
target: thumbv7em-none-eabihf
image: default
- build: sidecar-c
app_name: sidecar-c
app_toml: app/sidecar/rev-c.toml
target: thumbv7em-none-eabihf
image: default
- build: sidecar-c-lab
app_name: sidecar-c-lab
app_toml: app/sidecar/rev-c-lab.toml
target: thumbv7em-none-eabihf
image: default
- build: sidecar-c-dev
app_name: sidecar-c-dev
app_toml: app/sidecar/rev-c-dev.toml
target: thumbv7em-none-eabihf
image: default
- build: psc-b
app_name: psc-b
app_toml: app/psc/rev-b.toml
target: thumbv7em-none-eabihf
image: default
- build: psc-b-dev
app_name: psc-b-dev
app_toml: app/psc/rev-b-dev.toml
target: thumbv7em-none-eabihf
image: default
- build: psc-c
app_name: psc-c
app_toml: app/psc/rev-c.toml
target: thumbv7em-none-eabihf
image: default
- build: psc-c-dev
app_name: psc-c-dev
app_toml: app/psc/rev-c-dev.toml
target: thumbv7em-none-eabihf
image: default
- build: oxide-rot-1
app_name: oxide-rot-1
app_toml: app/oxide-rot-1/app.toml
target: thumbv8m.main-none-eabihf
image: [a, b]
- build: oxide-rot-1-dev
app_name: oxide-rot-1-dev
app_toml: app/oxide-rot-1/app-dev.toml
target: thumbv8m.main-none-eabihf
image: [a, b]
- build: donglet-g031
app_name: donglet-g031
app_toml: app/donglet/app-g031.toml
target: thumbv6m-none-eabi
image: default
- os: ubuntu-latest
- os: windows-latest
env:
VCPKGRS_DYNAMIC: 1
steps:
# check out our code
- uses: actions/checkout@v3
# install rust toolchain
- name: Install Rust toolchain
run: rustup show
- name: Cache build output
uses: Swatinem/rust-cache@v2
- name: Cache vcpkg
uses: actions/cache@v3
with:
path: C:\vcpkg\downloads
key: ${{ runner.os }}-vcpkg-download-${{ matrix.os }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-vcpkg-download-${{ matrix.os }}-
${{ runner.os }}-vcpkg-download-
# invoke our build
- name: cargo xtask dist
env:
RUST_BACKTRACE: 1
run: cargo xtask dist ${{ matrix.app_toml}}
- name: Fetch Humility
uses: dsaltares/fetch-gh-release-asset@master
if: matrix.os == 'ubuntu-latest'
with:
repo: "oxidecomputer/humility"
version: "59047694"
file: "humility"
target: "target/release/humility"
token: ${{ secrets.GITHUB_TOKEN }}
- name: Test Humility manifest
# we need to chmod because all artifacts are marked as non-executable
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get update && sudo apt-get install libusb-1.0-0-dev libftdi1-dev
sudo chmod +x target/release/humility
for image in `echo ${{ join(matrix.image) }} | tr "," "\n"`; do \
mv target/${{ matrix.app_name }}/dist/$image/build-${{ matrix.app_name }}-image-$image.zip target/${{ matrix.app_name }}/dist/; \
target/release/humility -a target/${{ matrix.app_name }}/dist/build-${{ matrix.app_name }}-image-$image.zip manifest; \
done
# upload the output of our build
- name: Upload build archive
uses: actions/upload-artifact@v3
if: matrix.os == 'ubuntu-latest'
with:
name: dist-${{ matrix.os }}-${{ matrix.build }}
path: target/${{ matrix.app_name }}/dist/build-${{ matrix.app_name }}-image-*.zip