Skip to content

Upgrade android target sdk version to 34 (#23) #13

Upgrade android target sdk version to 34 (#23)

Upgrade android target sdk version to 34 (#23) #13

Workflow file for this run

name: Release
on:
push:
branches: [master]
paths-ignore:
- '**/README.md'
- 'docs/**'
workflow_dispatch:
env:
API_URL: ${{secrets.API_URL}}
KEYSTORE: ${{secrets.KEYSTORE}}
KEYSTORE_PASS: ${{secrets.KEYSTORE_PASS}}
jobs:
build:
name: Flutter Build
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
- name: Set up Flutter
uses: subosito/flutter-action@v2
with:
channel: stable
cache: true
flutter-version: 3.22.1
- name: Get version from pubspec.yaml
id: appVersion
uses: devorbitus/[email protected]
with:
cmd: yq eval '.version' 'pubspec.yaml'
# Get flutter dependencies.
- run: flutter pub get
# Check for any formatting issues in the code.
- run: dart format --set-exit-if-changed .
# Statically analyze the Dart code for any errors.
- run: flutter analyze .
# Run widget tests for our flutter project.
- run: flutter test
- name: Configure keystore
run: echo "$KEYSTORE" | base64 --decode > android/app/upload-keystore.jks
- name: Build app blundle
run: flutter build appbundle --dart-define=API_URL="$API_URL"
- name: Setup Fastlane
uses: ruby/setup-ruby@v1
with:
ruby-version: "2.7"
bundler-cache: true
working-directory: android
- name: Push beta release to Google Playstore
run: bundle exec fastlane beta
env:
PLAY_STORE_CONFIG_JSON: ${{ secrets.PLAY_STORE_CONFIG_JSON }}
working-directory: android
- name: Create release
uses: ncipollo/release-action@v1
with:
artifacts: "build/app/outputs/bundle/release/app-release.aab"
commit: master
tag: ${{ steps.appVersion.outputs.result }}
token: ${{ secrets.GITHUB_TOKEN }}