11plugins {
22 id " com.android.application"
33 id " kotlin-android"
4+ // The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
45 id " dev.flutter.flutter-gradle-plugin"
56}
6-
7- def localProperties = new Properties ()
8- def localPropertiesFile = rootProject. file(' local.properties' )
9- if (localPropertiesFile. exists()) {
10- localPropertiesFile. withReader(' UTF-8' ) { reader ->
11- localProperties. load(reader)
12- }
13- }
14-
15-
16- def flutterVersionCode = localProperties. getProperty(' flutter.versionCode' )
17- if (flutterVersionCode == null ) {
18- flutterVersionCode = ' 1'
19- }
20-
21- def flutterVersionName = localProperties. getProperty(' flutter.versionName' )
22- if (flutterVersionName == null ) {
23- flutterVersionName = ' 1.0'
24- }
25-
26-
277def keystoreProperties = new Properties ()
288def keystorePropertiesFile = rootProject. file(' key.properties' )
299if (keystorePropertiesFile. exists()) {
3010 keystoreProperties. load(new FileInputStream (keystorePropertiesFile))
3111}
3212
3313android {
34- compileSdkVersion 34
35- ndkVersion flutter. ndkVersion
14+ namespace = " com.xycz.simple_live"
15+ compileSdk = flutter. compileSdkVersion
16+ ndkVersion = flutter. ndkVersion
3617
3718 compileOptions {
38- sourceCompatibility JavaVersion . VERSION_1_8
39- targetCompatibility JavaVersion . VERSION_1_8
19+ sourceCompatibility = JavaVersion . VERSION_1_8
20+ targetCompatibility = JavaVersion . VERSION_1_8
4021 }
4122
4223 kotlinOptions {
43- jvmTarget = ' 1.8'
44- }
45-
46- sourceSets {
47- main. java. srcDirs + = ' src/main/kotlin'
24+ jvmTarget = JavaVersion . VERSION_1_8
4825 }
4926
5027 defaultConfig {
5128 // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
52- applicationId " com.xycz.simple_live"
29+ applicationId = " com.xycz.simple_live"
5330 // You can update the following values to match your application needs.
54- // For more information, see: https://docs. flutter.dev/deployment/android#reviewing-the- gradle-build-configuration .
55- minSdkVersion 21
31+ // For more information, see: https://flutter.dev/to/review- gradle-config .
32+ minSdk = flutter . minSdkVersion
5633 multiDexEnabled true
57- targetSdkVersion flutter. targetSdkVersion
58- versionCode flutterVersionCode . toInteger()
59- versionName flutterVersionName
34+ targetSdk = flutter. targetSdkVersion
35+ versionCode = flutter . versionCode
36+ versionName = flutter . versionName
6037 }
61-
6238 packagingOptions {
6339 pickFirst ' lib/**/libc++_shared.so'
6440 }
@@ -72,6 +48,7 @@ android {
7248 v2SigningEnabled true
7349 }
7450 }
51+
7552 buildTypes {
7653 buildTypes {
7754 debug {
@@ -93,9 +70,5 @@ android {
9370}
9471
9572flutter {
96- source ' ../..'
97- }
98-
99- dependencies {
100- implementation " org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.7.10"
73+ source = " ../.."
10174}
0 commit comments