Skip to content

Bump version

Bump version #25

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
workflow_dispatch:
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Bootstrap workspace
uses: ./.github/actions/bootstrap
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 21
cache: gradle
- name: Get Android keystore
id: android-keystore
uses: timheuer/base64-to-file@v1
with:
fileName: keystore.jks
encodedString: ${{ secrets.ANDROID_KEYSTORE_BASE64 }}
- name: Create key.properties
uses: GuillaumeFalourd/write-java-properties-file@v1
with:
file_path: ./android/key.properties
property: |
storeFile
storePassword
keyPassword
keyAlias
value: |
${{ steps.android-keystore.outputs.filePath }}
${{ secrets.ANDROID_KEYSTORE_PASSWORD }}
${{ secrets.ANDROID_KEY_PASSWORD }}
${{ secrets.ANDROID_KEY_ALIAS }}
- name: Build Android APK
run: fvm flutter build apk
- name: Build Android App Bundle
run: fvm flutter build appbundle
- name: Upload APK artifact
uses: actions/upload-artifact@v4
with:
name: app-release.apk
path: build/app/outputs/apk/release/app-release.apk
- name: Upload App Bundle artifact
uses: actions/upload-artifact@v4
with:
name: app-release.aab
path: build/app/outputs/bundle/release/app-release.aab
release-github:
name: Release to GitHub
runs-on: ubuntu-latest
needs: build
if: startsWith(github.ref, 'refs/tags/')
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Parse pubspec
id: pubspec
uses: altive/pubspec-metadata@v1
- name: Get artifact
id: download-artifact
uses: actions/download-artifact@v4
with:
name: app-release.apk
- name: Release
uses: softprops/action-gh-release@v1
with:
body_path: fastlane/metadata/android/en-US/changelogs/${{ steps.pubspec.outputs.build-number }}.txt
files: app-release.apk
release-play-store:
name: Release to Play Store
runs-on: ubuntu-latest
needs: build
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.3
bundler-cache: true
- name: Get artifact
id: download-artifact
uses: actions/download-artifact@v4
with:
name: app-release.aab
- name: Release to Google Play
run: bundle exec fastlane supply --aab app-release.aab
env:
SUPPLY_PACKAGE_NAME: ${{ secrets.ANDROID_PACKAGE_NAME }}
SUPPLY_JSON_KEY_DATA: ${{ secrets.GOOGLE_SERVICE_ACCOUNT_KEY }}