Itch.io Deploy #126
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Itch.io Deploy | |
on: | |
workflow_run: | |
workflows: ["Unit Tests"] | |
types: [completed] | |
branches: [edge, prod] | |
jobs: | |
export-windows: | |
if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
name: Windows Export | |
runs-on: ubuntu-20.04 | |
container: | |
image: barichello/godot-ci:4.3 | |
environment: Godot Dev Env | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
lfs: true | |
- name: Setup | |
run: | | |
mkdir -v -p ~/.config/ | |
mv /root/.config/godot ~/.config/godot | |
mkdir -v -p ~/.local/share/godot/export_templates/ | |
mv /root/.local/share/godot/export_templates/${{ vars.GODOT_VERSION }}.stable ~/.local/share/godot/export_templates/${{ vars.GODOT_VERSION }}.stable | |
- name: Initial Godot import | |
shell: bash | |
run: | | |
godot --quiet --editor --headless -s src/core/initial_import.gd || exit 0 | |
godot --editor --headless --quit || exit 0 | |
- name: Windows Build | |
run: | | |
mkdir -v -p dist/dino-windows | |
godot --headless -v --export-debug dino-windows dist/dino-windows/dino.exe || exit 0 | |
- name: Sanity check | |
run: | | |
ls -alh dist/ | |
ls -alh dist/dino-windows | |
stat dist/dino-windows/dino.exe | |
- name: Deploy windows to itch.io | |
run: BUTLER_API_KEY=${{secrets.BUTLER_API_KEY}} butler push dist/dino-windows russmatney/dino:windows | |
export-linux: | |
if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
name: Linux Export | |
runs-on: ubuntu-20.04 | |
container: | |
image: barichello/godot-ci:4.3 | |
environment: Godot Dev Env | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
lfs: true | |
- name: Setup | |
run: | | |
mkdir -v -p ~/.config/ | |
mv /root/.config/godot ~/.config/godot | |
mkdir -v -p ~/.local/share/godot/export_templates/ | |
mv /root/.local/share/godot/export_templates/${{ vars.GODOT_VERSION }}.stable ~/.local/share/godot/export_templates/${{ vars.GODOT_VERSION }}.stable | |
- name: Initial Godot import | |
shell: bash | |
run: | | |
godot --quiet --editor --headless -s src/core/initial_import.gd || exit 0 | |
godot --editor --headless --quit || exit 0 | |
- name: Linux Build | |
run: | | |
mkdir -v -p dist/dino-linux | |
godot --headless -v --export-debug dino-linux dist/dino-linux/dino.x86_64 || exit 0 | |
- name: Sanity check | |
run: | | |
ls -alh dist/ | |
ls -alh dist/dino-linux | |
stat dist/dino-linux/dino.x86_64 | |
- name: Deploy linux to itch.io | |
run: BUTLER_API_KEY=${{secrets.BUTLER_API_KEY}} butler push dist/dino-linux russmatney/dino:linux | |
export-web: | |
if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
name: Web Export | |
runs-on: ubuntu-20.04 | |
container: | |
image: barichello/godot-ci:4.3 | |
environment: Godot Dev Env | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
lfs: true | |
- name: Setup | |
run: | | |
mkdir -v -p ~/.config/ | |
mv /root/.config/godot ~/.config/godot | |
mkdir -v -p ~/.local/share/godot/export_templates/ | |
mv /root/.local/share/godot/export_templates/${{ vars.GODOT_VERSION }}.stable ~/.local/share/godot/export_templates/${{ vars.GODOT_VERSION }}.stable | |
- name: Initial Godot import | |
shell: bash | |
run: | | |
godot --quiet --editor --headless -s src/core/initial_import.gd || exit 0 | |
godot --editor --headless --quit || exit 0 | |
- name: Web Build | |
run: | | |
mkdir -v -p dist/dino-web | |
godot --headless -v --export-debug dino-web dist/dino-web/index.html || exit 0 | |
- name: Sanity check | |
run: | | |
ls -alh dist/ | |
ls -alh dist/dino-web | |
stat dist/dino-web/index.html | |
- name: Deploy web build to itch.io (dino) | |
run: BUTLER_API_KEY=${{secrets.BUTLER_API_KEY}} butler push dist/dino-web russmatney/dino:html5 | |
- name: Deploy web build to itch.io (dino-web) | |
run: BUTLER_API_KEY=${{secrets.BUTLER_API_KEY}} butler push dist/dino-web russmatney/dino-web:html5 | |
# export-mac: | |
# if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
# name: Mac Export | |
# runs-on: ubuntu-20.04 | |
# container: | |
# image: barichello/godot-ci:4.3 | |
# environment: Godot Dev Env | |
# steps: | |
# - name: Checkout | |
# uses: actions/checkout@v4 | |
# with: | |
# lfs: true | |
# - name: Issue 120 | |
# run: | | |
# mkdir -p /github/home/.config/godot | |
# cp /root/.config/godot/editor_settings-4.tres /github/home/.config/godot/ | |
# - name: Sanity check | |
# run: ls /root/.local/share/godot/export_templates | |
# - name: Setup | |
# run: | | |
# mkdir -v -p ~/.config/ | |
# mv /root/.config/godot ~/.config/godot | |
# mkdir -v -p ~/.local/share/godot/export_templates/ | |
# mv /root/.local/share/godot/export_templates/${{ vars.GODOT_VERSION }}.stable ~/.local/share/godot/export_templates/${{ vars.GODOT_VERSION }}.stable | |
# - name: Initial Godot import | |
# shell: bash | |
# run: | | |
# godot --quiet --editor --headless -s src/core/initial_import.gd || exit 0 | |
# godot --editor --headless --quit || exit 0 | |
# - name: Mac Build | |
# run: | | |
# mkdir -v -p dist/dino-macos | |
# godot --headless -v --export-debug dino-macos dist/dino-macos/dino.dmg || exit 0 | |
# - name: Sanity check | |
# run: | | |
# ls -alh dist/ | |
# ls -alh dist/dino-macos | |
# stat dist/dino-macos/dino.dmg | |
# - name: Deploy mac build to itch.io | |
# run: BUTLER_API_KEY=${{secrets.BUTLER_API_KEY}} butler push dist/dino-macos russmatney/dino:macos |