plugins { id "com.android.application" id "kotlin-android" // The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins. id "dev.flutter.flutter-gradle-plugin" } def localProperties = new Properties() def localPropertiesFile = rootProject.file("local.properties") if (localPropertiesFile.exists()) { localPropertiesFile.withReader("UTF-8") { reader -> localProperties.load(reader) } } def flutterVersionCode = localProperties.getProperty("flutter.versionCode") if (flutterVersionCode == null) { flutterVersionCode = "1" } def flutterVersionName = localProperties.getProperty("flutter.versionName") if (flutterVersionName == null) { flutterVersionName = "1.0" } android { namespace = "cn.yooss.moodiary" compileSdk = 36 ndkVersion = "28.0.13004108" compileOptions { sourceCompatibility = JavaVersion.VERSION_21 targetCompatibility = JavaVersion.VERSION_21 } kotlinOptions { jvmTarget = JavaVersion.VERSION_21.toString() } signingConfigs { config { storeFile file('key.jks') storePassword localProperties.getProperty('storePassword') keyPassword localProperties.getProperty('keyPassword') keyAlias 'key0' enableV3Signing true } } defaultConfig { applicationId = "cn.yooss.moodiary" // You can update the following values to match your application needs. // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration. minSdk = 26 targetSdk = 36 versionCode = flutterVersionCode.toInteger() versionName = flutterVersionName ndk { //noinspection ChromeOsAbiSupport abiFilters 'arm64-v8a' } } buildTypes { release { signingConfig = signingConfigs.config minifyEnabled true shrinkResources true proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' } debug { signingConfig = signingConfigs.config resValue "string", "app_name", "Moodiary Debug" applicationIdSuffix ".debug" versionNameSuffix "-debug" } profile { signingConfig = signingConfigs.config } } } flutter { source = "../.." } dependencies { implementation 'com.github.gzu-liyujiang:Android_CN_OAID:4.2.11' implementation 'com.google.android.material:material:1.12.0' }