Skip to content

Build Android (.apk(s)) #33

Build Android (.apk(s))

Build Android (.apk(s)) #33

Workflow file for this run

# Build fat apk and splitted apk(s)
name: Build Android (.apk(s))
"on":
workflow_dispatch:
inputs:
flutterChannel:
description: "Flutter channel"
default: stable
required: true
type: choice
options:
- stable
- beta
- master
jobs:
build_android:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Setup Java
uses: actions/setup-java@v3
with:
distribution: "zulu"
java-version: "11"
- name: Setup Flutter
uses: subosito/flutter-action@v2
with:
channel: ${{ inputs.flutterChannel }}
- name: Decoding android/key.properties
run: echo "${{ secrets.KEY_PROP }}" | base64 --decode > android/key.properties
- name: Decoding android/key.jks
run: echo "${{ secrets.KEY_JKS }}" | base64 --decode > android/key.jks
- name: Get dependencies
run: flutter pub get
- name: Build app
run: flutter build apk --split-per-abi --release -v
- name: Upload artifacts (arm64-v8a)
uses: actions/upload-artifact@v3
with:
name: arm64-v8a artifact
path: build/app/outputs/apk/release/app-arm64-v8a-release.apk
- name: Upload artifacts (armeabi-v7a)
uses: actions/upload-artifact@v3
with:
name: armeabi-v7a artifact
path: build/app/outputs/apk/release/app-armeabi-v7a-release.apk
- name: Upload artifacts (x86_64)
uses: actions/upload-artifact@v3
with:
name: x86_64 artifact
path: build/app/outputs/apk/release/app-x86_64-release.apk
# - name: Build fat apk
# run: flutter build apk --release -v
# - name: Upload artifacts
# uses: actions/upload-artifact@v3
# with:
# name: fat apk artifact
# path: build/app/outputs/apk/release/app-release.apk
- name: Write summary
run: |
echo ":blue_heart: Using **`flutter --version`**" >> $GITHUB_STEP_SUMMARY