File tree Expand file tree Collapse file tree 2 files changed +4
-14
lines changed
Expand file tree Collapse file tree 2 files changed +4
-14
lines changed Original file line number Diff line number Diff line change @@ -54,11 +54,10 @@ jobs:
5454 uses : actions/cache@v3
5555 with :
5656 path : hugo-site/static/wasm
57- key : ${{ runner.os }}-wasm-${{ hashFiles('rust/gkwasm/**', 'rust/gklib/**') }}
57+ key : ${{ runner.os }}-wasm-${{ github.sha }}
5858
59- # Build WebAssembly if cache miss or files changed
59+ # Build WebAssembly
6060 - name : Build WebAssembly
61- if : steps.cache-wasm.outputs.cache-hit != 'true' || hashFiles('rust/gkwasm/**', 'rust/gklib/**') != steps.cache-wasm.outputs.cache-primary-key
6261 run : cargo make build-wasm-release
6362
6463 # Build the site using cargo-make
Original file line number Diff line number Diff line change @@ -25,17 +25,8 @@ dependencies = [
2525[tasks .build-site ]
2626description = " Build WebAssembly and Hugo site for deployment"
2727script = """
28- if [ -n "$GITHUB_ACTIONS" ]; then
29- if [ -d "hugo-site/static/wasm" ] && [ -n "$(ls -A hugo-site/static/wasm)" ]; then
30- echo "Using cached WebAssembly files"
31- else
32- echo "WebAssembly files not found in cache, rebuilding..."
33- cargo make build-wasm-release
34- fi
35- else
36- echo "Building WebAssembly files..."
37- cargo make build-wasm-release
38- fi
28+ echo "Building WebAssembly files..."
29+ cargo make build-wasm-release
3930cd hugo-site
4031hugo --minify
4132echo "Contents of public/wasm after running hugo:"
You can’t perform that action at this time.
0 commit comments