1.3.3+38 #19
Workflow file for this run
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: Create GitHub Release | |
on: | |
push: | |
tags: | |
- '*' | |
workflow_dispatch: | |
jobs: | |
build: | |
name: Build Android App | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Java | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'zulu' | |
java-version: '17.x' | |
cache: gradle | |
- uses: subosito/flutter-action@v2 | |
with: | |
flutter-version: '3.22.1' | |
channel: 'stable' | |
cache: true | |
- name: Get dependencies | |
run: flutter pub get | |
- name: Download Android keystore | |
id: android_keystore | |
uses: timheuer/[email protected] | |
with: | |
fileName: sn-upload-keystore.jks | |
encodedString: ${{ secrets.ANDROID_KEYSTORE_BASE64 }} | |
- name: Create key.properties | |
run: | | |
echo "storeFile=${{ steps.android_keystore.outputs.filePath }}" > android/key.properties | |
echo "storePassword=${{ secrets.STORE_PASSWORD }}" >> android/key.properties | |
echo "keyPassword=${{ secrets.KEY_PASSWORD }}" >> android/key.properties | |
echo "keyAlias=${{ secrets.KEY_ALIAS }}" >> android/key.properties | |
- name: Build APK (split per ABI) | |
run: flutter build apk --split-per-abi --flavor prod | |
- name: Build App Bundle | |
run: flutter build appbundle --flavor prod | |
- name: Archive build artifacts | |
uses: actions/upload-artifact@v2 | |
with: | |
name: android-release | |
path: build/app/outputs/bundle/prodRelease/app-prod-release.aab | |
release: | |
name: Create GitHub Release | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Download build artifacts | |
uses: actions/download-artifact@v2 | |
with: | |
name: android-release | |
- name: List downloaded files | |
run: ls -R | |
- name: Release | |
uses: softprops/action-gh-release@v2 | |
with: | |
files: app-prod-release.aab | |
env: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |