From 90c241db96b06c7bb58b0335f2d6800387f68c25 Mon Sep 17 00:00:00 2001 From: Vadim <44135514+vodemn@users.noreply.github.com> Date: Thu, 23 Feb 2023 22:40:03 +0300 Subject: [PATCH] add version code in gradle --- .github/workflows/cd_prod.yml | 17 ++--------------- android/app/build.gradle | 4 +++- 2 files changed, 5 insertions(+), 16 deletions(-) diff --git a/.github/workflows/cd_prod.yml b/.github/workflows/cd_prod.yml index b0465fb..a8b5031 100644 --- a/.github/workflows/cd_prod.yml +++ b/.github/workflows/cd_prod.yml @@ -7,13 +7,6 @@ name: Build Prod App Bundle on: workflow_dispatch: - inputs: - versionCode: - description: 'Version code' - required: true - versionName: - description: 'Version name' - required: true jobs: build: @@ -49,18 +42,12 @@ jobs: flutter --version flutter pub get flutter pub run intl_utils:generate - - - name: Bump version - uses: chkfung/android-version-actions@v1.2.1 - with: - gradlePath: android/app/build.gradle - versionCode: ${{ github.event.inputs.versionCode }} - versionName: ${{ github.event.inputs.versionName }} - name: Build appbundle run: flutter build appbundle --release --flavor prod --dart-define cameraPreviewAspectRatio=2/3 -t lib/main_prod.dart - - uses: actions/upload-artifact@v3 + - name: Upload app bundle to artifacts + uses: actions/upload-artifact@v3 with: name: m3_lightmeter_bundle path: build/app/outputs/bundle/prodRelease/app-prod-release.aab diff --git a/android/app/build.gradle b/android/app/build.gradle index 5a98f8f..9f8259d 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -51,7 +51,9 @@ android { defaultConfig { minSdkVersion 21 targetSdkVersion flutter.targetSdkVersion - versionCode flutterVersionCode.toInteger() + /// legacy material-lightmeter ap stopped updating after 60022 + /// 7xxxx means that it is a new app + versionCode 70000 + flutterVersionCode.toInteger() versionName flutterVersionName }