release v0.1.0 #5
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: Android Release | |
on: | |
push: | |
tags: | |
- "v*" | |
workflow_dispatch: | |
jobs: | |
build: | |
name: Build and Release APK | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Java | |
uses: actions/setup-java@v4 | |
with: | |
distribution: "zulu" | |
java-version: "17" | |
- name: Setup Flutter | |
uses: subosito/flutter-action@v2 | |
with: | |
flutter-version: "3.24.1" | |
channel: "stable" | |
- name: Get dependencies | |
run: flutter pub get | |
- name: Decode Keystore | |
env: | |
KEYSTORE_BASE64: ${{ secrets.KEYSTORE_BASE64 }} | |
run: | | |
echo $KEYSTORE_BASE64 | base64 -d > android/app/keystore.jks | |
- name: Build APK | |
env: | |
KEY_ALIAS: ${{ secrets.KEY_ALIAS }} | |
KEY_PASSWORD: ${{ secrets.KEY_PASSWORD }} | |
STORE_PASSWORD: ${{ secrets.STORE_PASSWORD }} | |
run: flutter build apk --release | |
- name: Upload APK | |
uses: actions/upload-artifact@v4 | |
with: | |
name: release-apk | |
path: build/app/outputs/flutter-apk/app-release.apk | |
- name: Create Release | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
files: build/app/outputs/flutter-apk/app-release.apk | |
draft: false | |
prerelease: false | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |