mirror of
https://github.com/Orama-Interactive/Pixelorama.git
synced 2025-01-18 09:09:47 +00:00
Attempt to fix Web builds in GitHub Pages using a workaround for SharedArrayBuffer
Thanks to e4c1d959e6/.github/workflows/Pipeline.yml (L107-L112)
This commit is contained in:
parent
91bfef16b3
commit
adbf1dc63f
6
.github/workflows/dev-web.yml
vendored
6
.github/workflows/dev-web.yml
vendored
|
@ -32,6 +32,12 @@ jobs:
|
|||
- name: Install rsync 📚
|
||||
run: |
|
||||
apt-get update && apt-get install -y rsync
|
||||
# Workaround for SharedArrayBuffer support on GitHub Pages
|
||||
# See: https://github.com/godotengine/godot-docs/issues/7084
|
||||
- run: |
|
||||
cd ./build/web
|
||||
curl -fsSL https://github.com/gzuidhof/coi-serviceworker/raw/master/coi-serviceworker.js > coi-serviceworker.js
|
||||
sed -i 's#\( <script src="index.js"></script>\)# <script src="coi-serviceworker.js"></script>\n\1#g' index.html
|
||||
- name: Deploy 🚀
|
||||
uses: JamesIves/github-pages-deploy-action@v4
|
||||
with:
|
||||
|
|
12
.github/workflows/release.yml
vendored
12
.github/workflows/release.yml
vendored
|
@ -193,12 +193,18 @@ jobs:
|
|||
- name: Install rsync 📚
|
||||
run: |
|
||||
apt-get update && apt-get install -y rsync
|
||||
- name: Upload Release Assets to itch.io 🎮
|
||||
run: |
|
||||
butler push ./build/web ${{ secrets.ITCHIO_USERNAME }}/${{ secrets.ITCHIO_GAME }}:web --userversion ${{env.TAG}}
|
||||
# Workaround for SharedArrayBuffer support on GitHub Pages
|
||||
# See: https://github.com/godotengine/godot-docs/issues/7084
|
||||
- run: |
|
||||
cd ./build/web
|
||||
curl -fsSL https://github.com/gzuidhof/coi-serviceworker/raw/master/coi-serviceworker.js > coi-serviceworker.js
|
||||
sed -i 's#\( <script src="index.js"></script>\)# <script src="coi-serviceworker.js"></script>\n\1#g' index.html
|
||||
- name: Deploy 🚀
|
||||
uses: JamesIves/github-pages-deploy-action@v4
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
single-commit: true
|
||||
folder: build/web # The folder the action should deploy.
|
||||
- name: Upload Release Assets to itch.io 🎮
|
||||
run: |
|
||||
butler push ./build/web ${{ secrets.ITCHIO_USERNAME }}/${{ secrets.ITCHIO_GAME }}:web --userversion ${{env.TAG}}
|
||||
|
|
Loading…
Reference in a new issue