Skip to content

Commit 9f740aa

Browse files
committed
Add build option to invalidate caches
Usually not needed, but just to be sure.
1 parent 6389290 commit 9f740aa

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

.github/workflows/build.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ jobs:
2424
EM_VERSION: 3.1.64
2525
EM_CACHE_FOLDER: "emsdk-cache"
2626
SCONS_CACHE: .scons-cache
27+
CACHE_VERSION: 1 # Invalidate cache by increasing this number
2728

2829
strategy:
2930
fail-fast: false
@@ -116,7 +117,7 @@ jobs:
116117
uses: actions/cache@v4
117118
with:
118119
path: ${{env.EM_CACHE_FOLDER}}
119-
key: ${{env.EM_VERSION}}-${{ env.BUILD_ID }}
120+
key: ${{env.EM_VERSION}}-${{ env.BUILD_ID }}-${{ env.CACHE_VERSION }}
120121

121122
- name: (Web) Set up Emscripten
122123
if: ${{ matrix.platform == 'web' }}
@@ -148,7 +149,7 @@ jobs:
148149
uses: actions/cache@v4
149150
with:
150151
path: ${{ env.SCONS_CACHE }}
151-
key: ${{ env.BUILD_ID }}
152+
key: ${{ env.BUILD_ID }}-${{ env.CACHE_VERSION }}
152153

153154
- name: Compile extension
154155
shell: sh

0 commit comments

Comments
 (0)