Newer
Older
apply plugin: 'com.android.application'
apply plugin: 'org.jetbrains.kotlin.android'
apply plugin: 'androidx.navigation.safeargs.kotlin'
apply plugin: 'kotlin-kapt'
apply plugin: 'dagger.hilt.android.plugin'
minSdk rootProject.ext.min_sdk_version
targetSdk rootProject.ext.sdk_version
archivesBaseName = "circles-v${versionName}"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
splits {
abi {
enable true
reset()
include "x86", "x86_64", "arm64-v8a", "armeabi-v7a"
universalApk false
}
}
release {
Properties properties = new Properties()
if (rootProject.file("signing.properties").exists()) {
properties.load(rootProject.file("signing.properties").newDataInputStream())
storeFile file(properties.getProperty("KEY_PATH"))
storePassword properties.getProperty("KEY_PASSWORD")
keyAlias properties.getProperty("ALIAS_NAME")
keyPassword properties.getProperty("KEY_PASSWORD")
}
}
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
productFlavors {
gplay {
dimension flavor_dimension_name
}
fdroid {
dimension flavor_dimension_name
}
}
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
"-opt-in=kotlinx.coroutines.FlowPreview",
"-opt-in=kotlinx.coroutines.ExperimentalCoroutinesApi",
ext.abiCodes = ['armeabi-v7a': 1, 'x86': 2, 'x86_64': 3, 'arm64-v8a': 4]
import com.android.build.OutputFile
android.applicationVariants.configureEach { variant ->
variant.outputs.each { output ->
def baseAbiVersionCode = project.ext.abiCodes.get(output.getFilter(OutputFile.ABI))
if (baseAbiVersionCode != null) {
output.versionCodeOverride =
implementation project(path: ':core')
implementation project(path: ':auth')
gplayImplementation platform('com.google.firebase:firebase-bom:32.7.0')
gplayImplementation 'com.google.firebase:firebase-crashlytics-ktx'
gplayImplementation 'com.google.firebase:firebase-analytics-ktx'
gplayImplementation 'com.google.firebase:firebase-messaging-ktx'
implementation 'com.github.UnifiedPush:android-connector:2.1.1'
implementation 'com.vanniktech:emoji-google:0.18.0'
//Log
implementation 'com.jakewharton.timber:timber:5.0.1'
implementation "com.google.dagger:hilt-android:$rootProject.ext.hilt_version"
kapt "com.google.dagger:hilt-compiler:$rootProject.ext.hilt_version"
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
if (getGradle().getStartParameter().getTaskRequests().toString().toLowerCase().contains("gplay")) {
apply plugin: 'com.google.gms.google-services'
apply plugin: 'com.google.firebase.crashlytics'