This commit is contained in:
TheGiddyLimit
2024-01-10 17:30:40 +00:00
parent e3bf75f42a
commit 5ffd4acdb4
26 changed files with 473 additions and 322 deletions

View File

@@ -11,5 +11,3 @@ version=$1
# Set the IS_DEPLOYED variable for production.
sed -i 's/IS_DEPLOYED\s*=\s*undefined/IS_DEPLOYED='"\"${version}\""'/g' js/utils.js
sed -i 's#DEPLOYED_IMG_ROOT\s*=\s*undefined#DEPLOYED_IMG_ROOT='"\"https://raw.githubusercontent.com/5etools-mirror-2/5etools-img/main/\""'#g' js/utils.js

5
.github/set-img-root.sh vendored Normal file
View File

@@ -0,0 +1,5 @@
#!/bin/bash
set -e
sed -i 's#DEPLOYED_IMG_ROOT\s*=\s*undefined#DEPLOYED_IMG_ROOT='"\"https://raw.githubusercontent.com/5etools-mirror-2/5etools-img/main/\""'#g' js/utils.js

View File

@@ -32,16 +32,17 @@ jobs:
- name: Checkout
uses: actions/checkout@master
- name: Set Deployed Flag
- name: Set Deployed Flag and Image Root
run: |
bash ./.github/set-deployed-flag.sh ${{ github.ref_name }}
bash ./.github/set-img-root.sh
# Notably: remove anything which should not be added to the service worker manifest:
# - `homebrew`
# - `prerelease`
- name: Cleanup
run: |
rm -rf .gitmodules *.md *.zip scss spellcheck homebrew prerelease
rm -rf *.md *.zip scss spellcheck homebrew prerelease
ls -lah
# Remove entries from the `.gitignore` so the gh-pages action can correctly add+commit them to the pages branch