-
Notifications
You must be signed in to change notification settings - Fork 236
245 lines (207 loc) · 6.31 KB
/
ci.yml
File metadata and controls
245 lines (207 loc) · 6.31 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
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
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
name: CI
on:
# See: https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#pull_request.
pull_request:
# See: https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#push.
push:
branches:
- '**'
tags-ignore:
- '**'
concurrency:
group: ${{ github.event_name != 'pull_request' && github.run_id || github.ref }}
cancel-in-progress: true
env:
LC_ALL: 'C.UTF-8'
LANG: 'C.UTF-8'
LANGUAGE: 'C.UTF-8'
jobs:
non-device-tests:
name: Non-device tests
runs-on: ubuntu-latest
container: python:3.12
steps:
- uses: actions/checkout@v4
- run: |
pip install poetry
poetry install
- name: Run tests
run: |
cd test; poetry run ./run_tests.py; cd ..
lint:
name: lint
runs-on: ubuntu-latest
container: python:3.12
steps:
- uses: actions/checkout@v4
- run: |
pip install poetry
poetry install
- run: |
poetry run flake8
wine-builder:
name: Wine builder
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: docker/build-push-action@v6
with:
context: .
file: contrib/build-wine.Dockerfile
tags: build-wine-container
load: true
- run: >
docker run --rm \
--volume ${{ github.workspace }}:${{ github.workspace }} \
--workdir ${{ github.workspace }} \
build-wine-container bash -c "
git config --global --add safe.directory ${{ github.workspace }}
contrib/build_wine.sh
find dist -type f -exec sha256sum {} \;
"
dist-builder:
name: Dist builder
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: docker/build-push-action@v6
with:
context: .
file: contrib/build.Dockerfile
tags: build-container
load: true
- run: >
docker run --rm \
--volume ${{ github.workspace }}:${{ github.workspace }} \
--workdir ${{ github.workspace }} \
build-container bash -c "
git config --global --add safe.directory ${{ github.workspace }}
contrib/build_bin.sh
contrib/build_dist.sh
find dist -type f -exec sha256sum {} \;
"
- uses: actions/upload-artifact@v4
with:
name: dist
path: dist/
prepare-sim-matrices:
name: Prepare sim matrices
uses: ./.github/workflows/prepare-sim-matrices.yml
sim-builder-trezor:
name: Trezor sim builder
needs: prepare-sim-matrices
uses: ./.github/workflows/sim-builder.yml
with:
sim: trezor
include: ${{ needs.prepare-sim-matrices.outputs.trezor }}
runs-on: ubuntu-latest
sim-builder-coldcard:
name: Coldcard sim builder
needs: prepare-sim-matrices
uses: ./.github/workflows/sim-builder.yml
with:
sim: coldcard
include: ${{ needs.prepare-sim-matrices.outputs.coldcard }}
runs-on: ubuntu-latest
sim-builder-bitbox:
name: Bitbox sim builder
needs: prepare-sim-matrices
uses: ./.github/workflows/sim-builder.yml
with:
sim: bitbox
include: ${{ needs.prepare-sim-matrices.outputs.bitbox }}
runs-on: ubuntu-latest
sim-builder-jade:
name: Jade sim builder
needs: prepare-sim-matrices
uses: ./.github/workflows/sim-builder.yml
with:
sim: jade
include: ${{ needs.prepare-sim-matrices.outputs.jade }}
runs-on: ubuntu-latest
sim-builder-ledger:
name: Ledger sim builder
needs: prepare-sim-matrices
uses: ./.github/workflows/sim-builder.yml
with:
sim: ledger
include: ${{ needs.prepare-sim-matrices.outputs.ledger }}
runs-on: ubuntu-latest
sim-builder-keepkey:
name: Keepkey sim builder
needs: prepare-sim-matrices
uses: ./.github/workflows/sim-builder.yml
with:
sim: keepkey
include: ${{ needs.prepare-sim-matrices.outputs.keepkey }}
runs-on: ubuntu-latest
ledger-legacy-app-builder:
name: Ledger Bitcoin Legacy App builder
uses: ./.github/workflows/ledger-legacy-app-builder.yml
with:
runs-on: ubuntu-latest
ledger-app-builder:
name: Ledger Bitcoin App builder
uses: ./.github/workflows/ledger-app-builder.yml
with:
runs-on: ubuntu-latest
bitcoind-builder:
name: bitcoind builder
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/build-bitcoind
test-trezor-1:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-trezor, bitcoind-builder, dist-builder]
with:
device: trezor-1
runs-on: ubuntu-latest
test-trezor-t:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-trezor, bitcoind-builder, dist-builder]
with:
device: trezor-t
runs-on: ubuntu-latest
test-ledger-legacy:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-ledger, ledger-legacy-app-builder, bitcoind-builder, dist-builder]
with:
device: ledger-legacy
runs-on: ubuntu-latest
test-ledger:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-ledger, ledger-app-builder, bitcoind-builder, dist-builder]
with:
device: ledger
runs-on: ubuntu-latest
test-coldcard:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-coldcard, bitcoind-builder, dist-builder]
with:
device: coldcard
runs-on: ubuntu-latest
test-bitbox01:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-bitbox, bitcoind-builder, dist-builder]
with:
device: bitbox01
runs-on: ubuntu-latest
test-bitbox02:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-bitbox, bitcoind-builder, dist-builder]
with:
device: bitbox02
runs-on: ubuntu-latest
test-jade:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-jade, bitcoind-builder, dist-builder]
with:
device: jade
runs-on: ubuntu-latest
test-keepkey:
uses: ./.github/workflows/device-test.yml
needs: [sim-builder-keepkey, bitcoind-builder, dist-builder]
with:
device: keepkey
runs-on: ubuntu-latest