From 33d2fbef7db48907e26e76ec3892dc03cb2f3a99 Mon Sep 17 00:00:00 2001 From: OroshiX Date: Sun, 29 Sep 2024 21:21:28 +0200 Subject: [PATCH] Fix gradle --- android/app/build.gradle | 28 +++++++++---------- .../gradle/wrapper/gradle-wrapper.properties | 2 +- android/settings.gradle | 4 +-- 3 files changed, 17 insertions(+), 17 deletions(-) diff --git a/android/app/build.gradle b/android/app/build.gradle index 25bf30a..54193b3 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -18,18 +18,18 @@ if (keystorePropertiesFile.exists()) { keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) } -def flutterVersionCode = localProperties.getProperty('flutter.versionCode') -if (flutterVersionCode == null) { - flutterVersionCode = '1' -} +android { + compileSdk = flutter.compileSdkVersion + ndkVersion = flutter.ndkVersion -def flutterVersionName = localProperties.getProperty('flutter.versionName') -if (flutterVersionName == null) { - flutterVersionName = '1.0' -} + compileOptions { + sourceCompatibility = JavaVersion.VERSION_1_8 + targetCompatibility = JavaVersion.VERSION_1_8 + } -android { - compileSdkVersion 34 + kotlinOptions { + jvmTarget = JavaVersion.VERSION_1_8 + } sourceSets { main.java.srcDirs += 'src/main/kotlin' @@ -37,10 +37,10 @@ android { defaultConfig { applicationId "com.aroxoft.tagros.points" - minSdkVersion 26 - targetSdkVersion 34 - versionCode flutterVersionCode.toInteger() - versionName flutterVersionName + minSdkVersion flutter.minSdkVersion + targetSdkVersion flutter.targetSdkVersion + versionCode flutter.versionCode + versionName flutter.versionName testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } diff --git a/android/gradle/wrapper/gradle-wrapper.properties b/android/gradle/wrapper/gradle-wrapper.properties index 4511348..b0b3274 100644 --- a/android/gradle/wrapper/gradle-wrapper.properties +++ b/android/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ #Fri Jan 28 14:58:51 CET 2022 distributionBase=GRADLE_USER_HOME -distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.2-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-all.zip distributionPath=wrapper/dists zipStorePath=wrapper/dists zipStoreBase=GRADLE_USER_HOME diff --git a/android/settings.gradle b/android/settings.gradle index 5f2cb62..9608c6e 100644 --- a/android/settings.gradle +++ b/android/settings.gradle @@ -18,8 +18,8 @@ pluginManagement { plugins { id "dev.flutter.flutter-plugin-loader" version "1.0.0" - id "com.android.application" version "7.4.2" apply false - id "org.jetbrains.kotlin.android" version "1.9.0" apply false + id "com.android.application" version "8.1.0" apply false + id "org.jetbrains.kotlin.android" version "1.8.22" apply false } include ":app"