Skip to content

Commit 664d8e0

Browse files
committed
COMP: Cache ExternalData and build against ITK main
Add GitHub Actions cache for ExternalData object stores in all three build jobs (build-test-cxx, build-test-python-superbuild, build-test-documentation). This avoids re-downloading 563 CID-addressed test data files on every CI run. Also update itk-git-tag from v6.0a02 to main to pick up CI fixes merged after that tag (ccache, dashboard script, etc.).
1 parent 9ff3db8 commit 664d8e0

1 file changed

Lines changed: 25 additions & 1 deletion

File tree

.github/workflows/build-test-publish.yml

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Build, test, publish
33
on: [push,pull_request]
44

55
env:
6-
itk-git-tag: "v6.0a02"
6+
itk-git-tag: "main"
77

88
jobs:
99
build-test-cxx:
@@ -57,6 +57,14 @@ jobs:
5757
cd ITK
5858
git checkout ${{ env.itk-git-tag }}
5959
60+
- name: Restore ExternalData cache
61+
uses: actions/cache@v4
62+
with:
63+
path: ${{ github.workspace }}/../bld/ExternalData/Objects
64+
key: externaldata-v1-${{ hashFiles('Ex/src/**/*.cid') }}
65+
restore-keys: |
66+
externaldata-v1-
67+
6068
- name: Build ITK
6169
if: matrix.os != 'windows-2022'
6270
run: |
@@ -169,6 +177,14 @@ jobs:
169177
- name: Get specific version of CMake, Ninja
170178
uses: lukka/get-cmake@v3.24.2
171179

180+
- name: Restore ExternalData cache
181+
uses: actions/cache@v4
182+
with:
183+
path: ${{ github.workspace }}/../bld/ExternalData/Objects
184+
key: externaldata-superbuild-v1-${{ matrix.os }}-${{ hashFiles('Ex/src/**/*.cid') }}
185+
restore-keys: |
186+
externaldata-superbuild-v1-${{ matrix.os }}-
187+
172188
- name: Fetch CTest driver script
173189
run: |
174190
curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITKSphinxExamples/dashboard/itkexamples_common.cmake -O
@@ -308,6 +324,14 @@ jobs:
308324
SITE_PACKAGES_DIR=$(python3 "-c" "from distutils import sysconfig; print(sysconfig.get_python_lib())")
309325
sed -i "6559d" ${SITE_PACKAGES_DIR}/sphinx/domains/cpp.py
310326
327+
- name: Restore ExternalData cache
328+
uses: actions/cache@v4
329+
with:
330+
path: ${{ github.workspace }}/../bld/ExternalData/Objects
331+
key: externaldata-docs-v1-${{ hashFiles('Ex/src/**/*.cid') }}
332+
restore-keys: |
333+
externaldata-docs-v1-
334+
311335
- name: Fetch CTest driver script
312336
run: |
313337
curl -L https://raw.githubusercontent.com/InsightSoftwareConsortium/ITKSphinxExamples/dashboard/itkexamples_common.cmake -O

0 commit comments

Comments
 (0)