Skip to content

Commit

Permalink
Feature/CI-CD (#22)
Browse files Browse the repository at this point in the history
* Initial CI changes

* Renaming godot-export action

* Rename godot-export

* Adding missing shell command

* removing project name

* Removing composite action

* Fixing if statement

* Restricting builds to main or on demand only

* Adding PWA support

* Disabling main for testing

* Fixing mobile bug

* Adding concurrency

* Fixing names

* Enabling on main only
  • Loading branch information
Gravedigger7789 committed Nov 28, 2021
1 parent 72c3de0 commit f22b6cf
Show file tree
Hide file tree
Showing 4 changed files with 122 additions and 4 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/godot-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: "Godot CI"
on:
workflow_dispatch:
push:
branches: [main]

concurrency: ci-${{ github.ref }}

jobs:
export-godot:
strategy:
matrix:
export_template: ["Windows Desktop", "HTML5"]
godot_version: [3.4]
name: Export
runs-on: ubuntu-latest
container:
image: barichello/godot-ci:${{ matrix.godot_version }}
steps:
- name: Checkout Code
uses: actions/checkout@v2
with:
lfs: true
- name: Setup Export Templates
run: |
mkdir -v -p ~/.local/share/godot/templates
mv /root/.local/share/godot/templates/${{ matrix.godot_version }}.stable ~/.local/share/godot/templates/${{ matrix.godot_version }}.stable
- name: Build Project
run: |
mkdir -v -p "build"
godot -v --export "${{ matrix.export_template }}"
- name: Upload Artifact
uses: actions/upload-artifact@v2
with:
name: ${{ matrix.export_template }}
path: build/
- name: Publish to GitHub Pages
if: matrix.export_template == 'HTML5'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build
7 changes: 3 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@

# Godot-specific ignores
.import/
export.cfg
export_presets.cfg
logs/
*.exe
*.pck

# Godot compiled binaries
build/

# Mono-specific ignores
.mono/
Expand Down
76 changes: 76 additions & 0 deletions export_presets.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
[preset.0]

name="Windows Desktop"
platform="Windows Desktop"
runnable=true
custom_features=""
export_filter="all_resources"
include_filter=""
exclude_filter=""
export_path="build/gh-game-off-bug.exe"
script_export_mode=1
script_encryption_key=""

[preset.0.options]

custom_template/debug=""
custom_template/release=""
binary_format/64_bits=true
binary_format/embed_pck=false
texture_format/bptc=false
texture_format/s3tc=true
texture_format/etc=false
texture_format/etc2=false
texture_format/no_bptc_fallbacks=true
codesign/enable=false
codesign/identity_type=0
codesign/identity=""
codesign/password=""
codesign/timestamp=true
codesign/timestamp_server_url=""
codesign/digest_algorithm=1
codesign/description=""
codesign/custom_options=PoolStringArray( )
application/icon=""
application/file_version="0.0.1"
application/product_version="0.0.1"
application/company_name="RacBros Gaming"
application/product_name="Bug Jam"
application/file_description=""
application/copyright=""
application/trademarks=""

[preset.1]

name="HTML5"
platform="HTML5"
runnable=true
custom_features=""
export_filter="all_resources"
include_filter=""
exclude_filter=""
export_path="build/index.html"
script_export_mode=1
script_encryption_key=""

[preset.1.options]

custom_template/debug=""
custom_template/release=""
variant/export_type=0
vram_texture_compression/for_desktop=true
vram_texture_compression/for_mobile=true
html/export_icon=true
html/custom_html_shell=""
html/head_include=""
html/canvas_resize_policy=2
html/focus_canvas_on_start=true
html/experimental_virtual_keyboard=false
progressive_web_app/enabled=true
progressive_web_app/offline_page=""
progressive_web_app/display=1
progressive_web_app/orientation=1
progressive_web_app/icon_144x144=""
progressive_web_app/icon_180x180=""
progressive_web_app/icon_512x512=""
progressive_web_app/background_color=Color( 0, 0, 0, 1 )
1 change: 1 addition & 0 deletions src/Level/SplashScreen.gd
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ func _input(event: InputEvent) -> void:
event.is_action_pressed("attack")
|| event.is_action_pressed("jump")
|| event.is_action_pressed("pause")
|| event is InputEventMouseButton
):
get_tree().set_input_as_handled()
var changed = get_tree().change_scene_to(first_scene)
Expand Down

0 comments on commit f22b6cf

Please sign in to comment.