Skip to content

Build Android apk

Build Android apk #30

Workflow file for this run

name: Build Android apk
on:
[workflow_dispatch]
permissions:
contents: read
jobs:
build-and-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 0
- uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'adopt'
- run: echo '{}' > lib/l10n/app_zh.arb
- run: vendor/flutter/bin/flutter pub get
- run: curl -L https://textual.ru/presets.db -o assets/presets.db
name: Download presets database
- run: vendor/flutter/bin/flutter test
- run: vendor/flutter/bin/flutter build apk --flavor beta
- uses: noriban/sign-android-release@v5
name: Sign app APK
id: sign_app
with:
releaseDirectory: build/app/outputs/flutter-apk
signingKeyBase64: ${{ secrets.KEYSTORE_JKS }}
alias: github
keyStorePassword: ${{ secrets.KEYSTORE_PASSWORD }}
keyPassword: ${{ secrets.KEYSTORE_PASSWORD }}
- name: Rename APK
run: mv ${{steps.sign_app.outputs.signedReleaseFile}} build/app/outputs/flutter-apk/EveryDoor-$(git log -n 1 --format='%h').apk
- name: Archive APK
uses: actions/upload-artifact@v4
with:
name: everydoor-apk
path: build/app/outputs/flutter-apk/EveryDoor*.apk
retention-days: 60