Browse Source

Kotlin DSL 语法(添加了 = 赋值符

liuyuqi-cnb 1 month ago
parent
commit
fbcca6f741
1 changed files with 8 additions and 8 deletions
  1. 8 8
      android/app/build.gradle.kts

+ 8 - 8
android/app/build.gradle.kts

@@ -8,7 +8,7 @@ plugins {
 android {
     namespace = "io.github.jianboy.flutter_clock"
     compileSdk = 36
-    ndkVersion = flutter.ndkVersion
+    ndkVersion = "27.0.12077973"
 
     compileOptions {
         sourceCompatibility = JavaVersion.VERSION_11
@@ -20,11 +20,11 @@ android {
     }
 
     signingConfigs {
-        release {
-            storeFile file("sign/flutter_clock.jks")
-            keyAlias "key0"
-            keyPassword "xf-ro9KM8NWP"
-            storePassword "xf-ro9KM8NWP"
+        create("release") {
+            storeFile = file("sign/flutter_clock.jks")
+            keyAlias = "key0"
+            keyPassword = "xf-ro9KM8NWP"
+            storePassword = "xf-ro9KM8NWP"
         }
     }
 
@@ -40,11 +40,11 @@ android {
     }
 
     buildTypes {
-        release {
+        getByName("release") {
             // TODO: Add your own signing config for the release build.
             // Signing with the debug keys for now, so `flutter run --release` works.
             //signingConfig = signingConfigs.getByName("debug")
-            signingConfig signingConfigs.release
+            signingConfig = signingConfigs.getByName("release")
         }
     }
 }