Skip to content

Commit dc95c7f

Browse files
committed
Don't make cache fail
1 parent ab2e435 commit dc95c7f

File tree

1 file changed

+28
-5
lines changed

1 file changed

+28
-5
lines changed

.github/workflows/build_wasm.yml

Lines changed: 28 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ env:
3131
libx11-dev libxcomposite-dev libxcursor-dev libxcursor-dev libxext-dev libxi-dev libxinerama-dev
3232
libxrandr-dev libxrender-dev libglu1-mesa-dev mesa-common-dev
3333
EM_VERSION: 3.1.45
34-
EM_CACHE_FOLDER: "emsdk-cache"
3534

3635
jobs:
3736
build_tests:
@@ -42,11 +41,17 @@ jobs:
4241
fetch-depth: 0
4342
- uses: seanmiddleditch/gha-setup-ninja@master
4443
- run: sudo apt-get update && sudo apt-get install -y ${INSTALL_DEPS}
44+
- name: Cache emsdk
45+
id: cache-emsdk
46+
uses: actions/cache@v4
47+
continue-on-error: true
48+
with:
49+
path: emsdk
50+
key: emsdk-${{ env.EM_VERSION }}-${{ runner.os }}
4551
- name: Setup emsdk
4652
uses: mymindstorm/setup-emsdk@v14
4753
with:
4854
version: ${{ env.EM_VERSION }}
49-
actions-cache-folder: ${{ env.EM_CACHE_FOLDER }}
5055
- name: Configure
5156
run: emcmake cmake ${{ github.workspace }} -G "Ninja Multi-Config" -B ${{ runner.workspace }}/build -DYUP_ENABLE_TESTS=ON -DYUP_ENABLE_EXAMPLES=ON
5257
- run: cmake --build ${{ runner.workspace }}/build --config Debug --parallel 4 --target yup_tests
@@ -64,11 +69,17 @@ jobs:
6469
fetch-depth: 0
6570
- uses: seanmiddleditch/gha-setup-ninja@master
6671
- run: sudo apt-get update && sudo apt-get install -y ${INSTALL_DEPS}
72+
- name: Cache emsdk
73+
id: cache-emsdk
74+
uses: actions/cache@v4
75+
continue-on-error: true
76+
with:
77+
path: emsdk
78+
key: emsdk-${{ env.EM_VERSION }}-${{ runner.os }}
6779
- name: Setup emsdk
6880
uses: mymindstorm/setup-emsdk@v14
6981
with:
7082
version: ${{ env.EM_VERSION }}
71-
actions-cache-folder: ${{ env.EM_CACHE_FOLDER }}
7283
- name: Configure
7384
run: emcmake cmake ${{ github.workspace }} -G "Ninja Multi-Config" -B ${{ runner.workspace }}/build -DYUP_ENABLE_TESTS=ON -DYUP_ENABLE_EXAMPLES=ON
7485
- run: cmake --build ${{ runner.workspace }}/build --config Debug --parallel 4 --target example_console
@@ -82,11 +93,17 @@ jobs:
8293
fetch-depth: 0
8394
- uses: seanmiddleditch/gha-setup-ninja@master
8495
- run: sudo apt-get update && sudo apt-get install -y ${INSTALL_DEPS}
96+
- name: Cache emsdk
97+
id: cache-emsdk
98+
uses: actions/cache@v4
99+
continue-on-error: true
100+
with:
101+
path: emsdk
102+
key: emsdk-${{ env.EM_VERSION }}-${{ runner.os }}
85103
- name: Setup emsdk
86104
uses: mymindstorm/setup-emsdk@v14
87105
with:
88106
version: ${{ env.EM_VERSION }}
89-
actions-cache-folder: ${{ env.EM_CACHE_FOLDER }}
90107
- name: Configure
91108
run: emcmake cmake ${{ github.workspace }} -G "Ninja Multi-Config" -B ${{ runner.workspace }}/build -DYUP_ENABLE_TESTS=ON -DYUP_ENABLE_EXAMPLES=ON
92109
- run: cmake --build ${{ runner.workspace }}/build --config Debug --parallel 4 --target example_app
@@ -100,11 +117,17 @@ jobs:
100117
fetch-depth: 0
101118
- uses: seanmiddleditch/gha-setup-ninja@master
102119
- run: sudo apt-get update && sudo apt-get install -y ${INSTALL_DEPS}
120+
- name: Cache emsdk
121+
id: cache-emsdk
122+
uses: actions/cache@v4
123+
continue-on-error: true
124+
with:
125+
path: emsdk
126+
key: emsdk-${{ env.EM_VERSION }}-${{ runner.os }}
103127
- name: Setup emsdk
104128
uses: mymindstorm/setup-emsdk@v14
105129
with:
106130
version: ${{ env.EM_VERSION }}
107-
actions-cache-folder: ${{ env.EM_CACHE_FOLDER }}
108131
- name: Configure
109132
run: emcmake cmake ${{ github.workspace }} -G "Ninja Multi-Config" -B ${{ runner.workspace }}/build -DYUP_ENABLE_TESTS=ON -DYUP_ENABLE_EXAMPLES=ON
110133
- run: cmake --build ${{ runner.workspace }}/build --config Debug --parallel 4 --target example_graphics

0 commit comments

Comments
 (0)