Skip to content

Commit d7b8bb2

Browse files
committed
CI: move check-hash to separate job.
- This makes it easier to see if CI fails on hashes (which might be expected during development) or something else.
1 parent 3cf2184 commit d7b8bb2

File tree

1 file changed

+33
-3
lines changed

1 file changed

+33
-3
lines changed

.github/workflows/ci.yaml

+33-3
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,40 @@ jobs:
6262
working-directory: hw/application_fpga
6363
run: make all
6464

65-
- name: check matching hashes for firmware.bin & application_fpga.bin
66-
working-directory: hw/application_fpga
67-
run: make check-binary-hashes
65+
- name: Cache binaries
66+
uses: actions/cache@v4
67+
with:
68+
path: |
69+
hw/application_fpga/application_fpga.bin
70+
hw/application_fpga/firmware.bin
71+
key: ${{ runner.os }}-build-${{ github.sha }}
72+
restore-keys: ${{ runner.os }}-build-
73+
6874

6975
# TODO? first deal with hw/boards/ and hw/production_test/
7076
# - name: check for SPDX tags
7177
# run: ./LICENSES/spdx-ensure
78+
79+
check-hashes:
80+
needs: ci
81+
runs-on: ubuntu-latest
82+
container:
83+
image: ghcr.io/tillitis/tkey-builder:4
84+
steps:
85+
- name: Checkout
86+
uses: actions/checkout@v4
87+
with:
88+
persist-credentials: false
89+
90+
- name: Retrieve binaries from cache
91+
uses: actions/cache@v4
92+
with:
93+
path: |
94+
hw/application_fpga/application_fpga.bin
95+
hw/application_fpga/firmware.bin
96+
key: ${{ runner.os }}-build-${{ needs.build.outputs.commit_sha }}
97+
restore-keys: ${{ runner.os }}-build-
98+
99+
- name: check matching hashes for firmware.bin & application_fpga.bin
100+
working-directory: hw/application_fpga
101+
run: make check-binary-hashes

0 commit comments

Comments
 (0)