Skip to content

Update android.yml #195

Update android.yml

Update android.yml #195

Workflow file for this run

name: Android CI
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
apk:
runs-on: ubuntu-latest
steps:
- name: Checkout repository and submodules
uses: actions/checkout@v3
with:
submodules: recursive
- name: set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
cache: gradle
- name: Set permissions for gradlew
run: chmod +x gradlew
- name: Install Ninja and check Android SDK
run: |
sudo apt-get update
sudo apt-get install -y ninja-build
echo "Ninja location and version:"
which ninja
ninja --version
echo "Android SDK location:"
echo $ANDROID_SDK_ROOT
echo "NDK location:"
ls -l /usr/local/lib/android/sdk/ndk/
- name: Check Ninja location
run: |
which ninja
ninja --version
- name: Build
run: ./gradlew build
- uses: ilharp/sign-android-release@v1
name: Sign app APK
# ID used to access action output
id: sign_app
with:
releaseDir: app/build/outputs/apk/release
signingKey: ${{ secrets.SIGNING_KEY }}
keyAlias: ${{ secrets.ALIAS }}
keyStorePassword: ${{ secrets.KEY_STORE_PASSWORD }}
keyPassword: ${{ secrets.KEY_PASSWORD }}
buildToolsVersion: 33.0.0
- name: Upload Debug APK
uses: actions/upload-artifact@v3
with:
name: debug-apk
path: app/build/outputs/apk/debug/app-debug.apk
- name: Upload Release APK
uses: actions/upload-artifact@v3
with:
name: release-apk
path: ${{steps.sign_app.outputs.signedFile}}
- name: Upload to Edge relaese
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh release upload Edge app/build/outputs/apk/debug/app-debug.apk --clobber
gh release upload Edge ${{steps.sign_app.outputs.signedFile}} --clobber