fix workflows (#36) #93
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: Android | |
on: | |
push: | |
branches: [ master ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Gluon's GraalVM | |
uses: gluonhq/setup-graalvm@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Setup Java | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'temurin' | |
java-version: '21' | |
- name: Install libraries | |
run: | | |
sudo apt-get update | |
sudo apt install libasound2-dev libavcodec-dev libavformat-dev libavutil-dev libgl-dev libgtk-3-dev libpango1.0-dev libxtst-dev | |
- name: Setup Android Keystore | |
id: android_keystore_file | |
uses: timheuer/base64-to-file@v1 | |
with: | |
fileName: 'my.keystore' | |
encodedString: ${{ secrets.GLUON_ANDROID_KEYSTORE_BASE64 }} | |
- name: Gluon License | |
uses: gluonhq/gluon-build-license@v1 | |
with: | |
gluon-license: ${{ secrets.GLUON_LICENSE }} | |
- name: Gluon Build | |
run: | | |
export ANDROID_SDK=$ANDROID_HOME | |
./mvnw -Pandroid gluonfx:build gluonfx:package | |
env: | |
GLUON_ANDROID_KEYSTOREPATH: ${{ steps.android_keystore_file.outputs.filePath }} | |
GLUON_ANDROID_KEYSTORE_PASSWORD: ${{ secrets.GLUON_ANDROID_KEYSTORE_PASSWORD }} | |
GLUON_ANDROID_KEYALIAS: ${{ secrets.GLUON_ANDROID_KEYALIAS }} | |
GLUON_ANDROID_KEYALIAS_PASSWORD: ${{ secrets.GLUON_ANDROID_KEYALIAS_PASSWORD }} | |
- name: Make staging directory | |
run: mkdir staging | |
- name: Copy packages to staging | |
run: cp -r target/gluonfx/aarch64-android/gvm/HelloGluon.* staging | |
- name: Upload | |
uses: actions/upload-artifact@v2 | |
with: | |
name: Package | |
path: staging | |
- name: Upload to Google Play | |
uses: r0adkll/[email protected] | |
with: | |
serviceAccountJsonPlainText: ${{ secrets.GLUON_ANDROID_SERVICE_ACCOUNT_JSON }} | |
packageName: com.gluonhq.samples.hellogluon | |
releaseFiles: target/gluonfx/aarch64-android/gvm/HelloGluon.aab | |
track: beta |