2024-08-04 14:50:37 +00:00
|
|
|
plugins {
|
|
|
|
id "com.android.application"
|
|
|
|
id "kotlin-android"
|
|
|
|
id "dev.flutter.flutter-gradle-plugin"
|
|
|
|
//id "com.google.gms.google-services"
|
|
|
|
}
|
|
|
|
|
2020-01-01 18:10:13 +00:00
|
|
|
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'
|
|
|
|
}
|
|
|
|
|
2020-01-02 23:15:12 +00:00
|
|
|
def keystoreProperties = new Properties()
|
|
|
|
def keystorePropertiesFile = rootProject.file('key.properties')
|
|
|
|
if (keystorePropertiesFile.exists()) {
|
|
|
|
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
|
|
|
}
|
|
|
|
|
2020-01-01 18:10:13 +00:00
|
|
|
android {
|
2023-10-28 18:54:23 +00:00
|
|
|
compileSdkVersion 34
|
2020-01-01 18:10:13 +00:00
|
|
|
|
|
|
|
sourceSets {
|
|
|
|
main.java.srcDirs += 'src/main/kotlin'
|
|
|
|
}
|
|
|
|
|
2021-01-28 17:50:29 +00:00
|
|
|
lintOptions {
|
|
|
|
disable 'InvalidPackage'
|
|
|
|
}
|
|
|
|
|
2020-01-01 18:10:13 +00:00
|
|
|
defaultConfig {
|
|
|
|
applicationId "chat.fluffy.fluffychat"
|
2023-11-22 06:51:16 +00:00
|
|
|
minSdkVersion 21
|
2024-07-16 06:48:45 +00:00
|
|
|
targetSdkVersion 34
|
2020-01-01 18:10:13 +00:00
|
|
|
versionCode flutterVersionCode.toInteger()
|
|
|
|
versionName flutterVersionName
|
|
|
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
2022-02-15 08:25:13 +00:00
|
|
|
multiDexEnabled true
|
2020-01-01 18:10:13 +00:00
|
|
|
}
|
|
|
|
|
2020-01-02 23:15:12 +00:00
|
|
|
signingConfigs {
|
|
|
|
release {
|
2020-01-03 10:47:31 +00:00
|
|
|
if (keystorePropertiesFile.exists()) {
|
|
|
|
keyAlias keystoreProperties['keyAlias']
|
|
|
|
keyPassword keystoreProperties['keyPassword']
|
|
|
|
storeFile file(keystoreProperties['storeFile'])
|
|
|
|
storePassword keystoreProperties['storePassword']
|
|
|
|
}
|
2020-01-02 23:15:12 +00:00
|
|
|
}
|
|
|
|
}
|
2020-01-01 18:10:13 +00:00
|
|
|
buildTypes {
|
2020-01-03 10:47:31 +00:00
|
|
|
debug {
|
|
|
|
signingConfig signingConfigs.debug
|
2023-10-28 10:36:46 +00:00
|
|
|
versionNameSuffix "-debug"
|
2020-01-03 10:47:31 +00:00
|
|
|
}
|
2020-01-01 18:10:13 +00:00
|
|
|
release {
|
2020-01-02 23:15:12 +00:00
|
|
|
signingConfig signingConfigs.release
|
2023-12-21 12:57:10 +00:00
|
|
|
}
|
2020-01-01 18:10:13 +00:00
|
|
|
}
|
2023-11-18 21:08:13 +00:00
|
|
|
// https://stackoverflow.com/a/77494454/8222484
|
|
|
|
packagingOptions {
|
|
|
|
pickFirst 'lib/x86/libc++_shared.so'
|
|
|
|
pickFirst 'lib/x86_64/libc++_shared.so'
|
|
|
|
pickFirst 'lib/armeabi-v7a/libc++_shared.so'
|
|
|
|
pickFirst 'lib/arm64-v8a/libc++_shared.so'
|
|
|
|
}
|
2020-01-01 18:10:13 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
flutter {
|
|
|
|
source '../..'
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2023-12-21 12:57:10 +00:00
|
|
|
//<GOOGLE_SERVICES>implementation 'com.google.firebase:firebase-messaging:19.0.1' // Workaround for https://github.com/microg/android_packages_apps_GmsCore/issues/313#issuecomment-617651698
|
2022-02-15 08:25:13 +00:00
|
|
|
implementation 'androidx.multidex:multidex:2.0.1'
|
2020-01-01 18:10:13 +00:00
|
|
|
}
|