test custom build action

This commit is contained in:
Nitwel 2023-12-11 20:42:47 +01:00
parent ccb9258fa7
commit 2c0a581722
3 changed files with 8 additions and 27 deletions

View File

@ -8,6 +8,9 @@ on:
env:
GODOT_VERSION: 4.2
EXPORT_NAME: immersive-home
GODOT_ANDROID_KEYSTORE_RELEASE_PATH: /home/runner/work/Immersive-Home/Immersive-Home/debug.keystore
GODOT_ANDROID_KEYSTORE_RELEASE_USER: androiddebugkey
GODOT_ANDROID_KEYSTORE_RELEASE_PASSWORD: android
jobs:
# job id, can be anything
@ -39,9 +42,6 @@ jobs:
run: |
keytool -keyalg RSA -genkeypair -alias androiddebugkey -keypass android -keystore debug.keystore -storepass android -dname "CN=Android Debug,O=Android,C=US" -validity 9999 -deststoretype pkcs12
mkdir -p ~/.config/godot
cp -v ./editor_settings-4.tres ~/.config/godot/
mkdir -p ./android/build
touch ./android/build/.gdignore
@ -54,7 +54,7 @@ jobs:
- name: export game
id: export
# Use latest version (see releases for all versions)
uses: moorbren/godot-export
uses: nitwel/godot-export@latest
with:
# Defining all the required inputs
godot_executable_download_url: https://downloads.tuxfamily.org/godotengine/4.2/Godot_v4.2-stable_linux.x86_64.zip

View File

@ -46,38 +46,22 @@ jobs:
echo "${{ secrets.KEYSTORE_RELEASE }}" | base64 -di > release.keystore
mkdir -p ~/.config/godot
cp -v ./editor_settings-4.tres ~/.config/godot/
mkdir -p ./android/build
touch ./android/build/.gdignore
wget -nv https://downloads.tuxfamily.org/godotengine/4.2/Godot_v4.2-stable_export_templates.tpz -O ./godot_templates.tpz
unzip -q ./godot_templates.tpz -d .
rm ./godot_templates.tpz
unzip -q ./templates/android_source.zip -d ./android/build/
rm ./templates/android_source.zip
sed -i 's/singleInstancePerTask/singleTask/g' ./android/build/AndroidManifest.xml
versioncode=$(eval "git tag | grep -v "test" | wc -l")
sed -i "s/BUILD_VERSION_CODE/$versioncode/g" export_presets.cfg
sed -i "s/android:versionCode=\"1\"/android:versionCode=\"$versioncode\"/g" ./android/build/AndroidManifest.xml
sed -i 's/BUILD_VERSION/${{ github.ref_name }}/g' export_presets.cfg
sed -i "s/android:versionName=\"1.0\"/android:versionName=\"${{ github.ref_name }}\"/g" ./android/build/AndroidManifest.xml
- name: export game
id: export
# Use latest version (see releases for all versions)
uses: moorbren/godot-export
uses: nitwel/godot-export@latest
with:
# Defining all the required inputs
godot_executable_download_url: https://downloads.tuxfamily.org/godotengine/4.2/Godot_v4.2-stable_linux.x86_64.zip
godot_export_templates_download_url: https://downloads.tuxfamily.org/godotengine/4.2/Godot_v4.2-stable_export_templates.tpz
relative_project_path: ./
archive_output: true
presets_to_export: "AndroidProduction"
filter_exports: "AndroidProduction"
version: ${{ github.ref_name }}"
production: true
- name: create release
uses: ncipollo/release-action@v1.11.2

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:05ad3273db12b74c881ed1cb4600bb2510f06656a0c48f1d7b0362080eede8d6
size 324