diff --git a/android/app/build.gradle b/android/app/build.gradle index 57e585ab125c372e3a5f6cd185ff46fee5b7417e..8a419ab85b3cf6a172bee872f271f1253b7bdc9c 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -66,10 +66,10 @@ import com.android.build.OutputFile android.applicationVariants.all { variant -> variant.outputs.each { output -> - def baseAbiVersionCode = project.ext.abiCodes.get(output.getFilter(OutputFile.ABI)) + def perAbiVersionCodeIncrement = project.ext.abiCodes.get(output.getFilter(OutputFile.ABI)) - if (baseAbiVersionCode != null) { - output.versionCodeOverride = baseAbiVersionCode * 1000 + variant.versionCode + if (perAbiVersionCodeIncrement != null) { + output.versionCodeOverride = variant.versionCode * 1000 + perAbiVersionCodeIncrement } } } diff --git a/pubspec.yaml b/pubspec.yaml index df35c73a3cdfe7fed306c50862acdb0c7b7a9000..0469327d44f0adcb64d3e7c3e905b585249454cb 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -3,7 +3,7 @@ description: A random application, for testing purpose only. publish_to: "none" -version: 1.0.61+62 +version: 1.0.62+63 environment: sdk: "^3.0.0" diff --git a/test.sh b/test.sh deleted file mode 100755 index 5bfee41b399d63bf5e03f14f6ae786dc7c9ec768..0000000000000000000000000000000000000000 --- a/test.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash -i - -BASE_APK_FOLDER="build/app/outputs/flutter-apk" -VERSION_NAME="$(grep '^version:' pubspec.yaml | cut -d' ' -f2 | cut -d'+' -f1)" -VERSION_CODE="$(grep '^version:' pubspec.yaml | cut -d' ' -f2 | cut -d'+' -f2)" -APP_NAME="$(grep 'namespace' android/app/build.gradle | cut -d'"' -f2)" - -if [ "$(find "${BASE_APK_FOLDER}" -name "*.apk")" != "" ]; then - for APK in ${BASE_APK_FOLDER}/*.apk; do - mv -v "${APK}" "$(echo "${APK}" | sed "s|\.apk|_${VERSION_CODE}.apk|" | sed "s|/app-|/${APP_NAME}-|")" - done -fi