2014-12-19 22:05:58 +00:00
|
|
|
apply plugin: 'com.android.application'
|
2018-05-23 17:45:46 +00:00
|
|
|
apply plugin: 'org.jetbrains.kotlin.android'
|
2014-12-19 22:05:58 +00:00
|
|
|
|
2016-05-28 12:26:56 +00:00
|
|
|
if (rootProject.testCoverage) {
|
|
|
|
apply plugin: 'jacoco'
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2020-05-18 23:03:32 +00:00
|
|
|
implementation project(":app:ui:legacy")
|
2018-06-21 13:12:50 +00:00
|
|
|
implementation project(":app:core")
|
2018-08-27 13:49:13 +00:00
|
|
|
implementation project(":app:storage")
|
2018-08-31 00:59:39 +00:00
|
|
|
implementation project(":app:crypto-openpgp")
|
2018-07-15 17:40:28 +00:00
|
|
|
implementation project(":backend:imap")
|
|
|
|
implementation project(":backend:pop3")
|
|
|
|
implementation project(":backend:webdav")
|
2018-02-17 03:05:09 +00:00
|
|
|
|
2019-02-09 04:23:37 +00:00
|
|
|
implementation "androidx.appcompat:appcompat:${versions.androidxAppCompat}"
|
2020-05-18 23:25:03 +00:00
|
|
|
implementation "androidx.core:core-ktx:${versions.androidxCore}"
|
2020-03-11 15:44:13 +00:00
|
|
|
implementation "com.takisoft.preferencex:preferencex:${versions.preferencesFix}"
|
2018-07-08 01:27:52 +00:00
|
|
|
implementation "com.jakewharton.timber:timber:${versions.timber}"
|
2020-05-07 09:36:08 +00:00
|
|
|
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:${versions.kotlinCoroutines}"
|
2018-07-08 01:27:52 +00:00
|
|
|
|
2020-07-15 21:23:05 +00:00
|
|
|
implementation "com.github.bumptech.glide:glide:${versions.glide}"
|
|
|
|
annotationProcessor "com.github.bumptech.glide:compiler:${versions.glide}"
|
|
|
|
|
2020-10-18 14:27:14 +00:00
|
|
|
if (project.hasProperty('k9mail.enableLeakCanary') && project.property('k9mail.enableLeakCanary') == "true") {
|
|
|
|
debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.4'
|
|
|
|
}
|
2020-05-16 19:06:06 +00:00
|
|
|
|
2020-06-23 14:29:46 +00:00
|
|
|
// Required for DependencyInjectionTest to be able to resolve OpenPgpApiManager
|
|
|
|
testImplementation project(':plugins:openpgp-api-lib:openpgp-api')
|
|
|
|
|
2018-06-29 14:12:20 +00:00
|
|
|
testImplementation "org.robolectric:robolectric:${versions.robolectric}"
|
|
|
|
testImplementation "junit:junit:${versions.junit}"
|
|
|
|
testImplementation "com.google.truth:truth:${versions.truth}"
|
|
|
|
testImplementation "org.mockito:mockito-core:${versions.mockito}"
|
2021-04-21 23:57:38 +00:00
|
|
|
testImplementation "org.mockito.kotlin:mockito-kotlin:${versions.mockitoKotlin}"
|
2018-06-29 14:12:20 +00:00
|
|
|
testImplementation "org.koin:koin-test:${versions.koin}"
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
android {
|
2018-05-23 17:36:52 +00:00
|
|
|
compileSdkVersion buildConfig.compileSdk
|
|
|
|
buildToolsVersion buildConfig.buildTools
|
2014-12-19 22:05:58 +00:00
|
|
|
|
|
|
|
defaultConfig {
|
2015-12-22 16:27:33 +00:00
|
|
|
applicationId "com.fsck.k9"
|
|
|
|
testApplicationId "com.fsck.k9.tests"
|
|
|
|
|
2021-04-30 21:54:36 +00:00
|
|
|
versionCode 27034
|
|
|
|
versionName '5.734'
|
2015-12-22 16:27:33 +00:00
|
|
|
|
2020-10-06 17:41:18 +00:00
|
|
|
// Keep in sync with the resource string array 'supported_languages'
|
2021-02-16 14:21:57 +00:00
|
|
|
resConfigs "in", "br", "ca", "cs", "cy", "da", "de", "et", "en", "en_GB", "es", "eo", "eu", "fr", "gd", "gl",
|
|
|
|
"hr", "is", "it", "lv", "lt", "hu", "nl", "nb", "pl", "pt_PT", "pt_BR", "ru", "ro", "sq", "sk", "sl",
|
2021-02-19 13:17:38 +00:00
|
|
|
"fi", "sv", "tr", "el", "be", "bg", "sr", "uk", "iw", "ar", "fa", "ml", "ko", "zh_CN", "zh_TW", "ja"
|
2020-10-06 17:41:18 +00:00
|
|
|
|
2018-05-23 17:36:52 +00:00
|
|
|
minSdkVersion buildConfig.minSdk
|
2019-11-17 00:28:52 +00:00
|
|
|
targetSdkVersion buildConfig.targetSdk
|
2014-12-20 06:39:08 +00:00
|
|
|
|
2020-05-09 13:43:52 +00:00
|
|
|
vectorDrawables.useSupportLibrary = true
|
2015-12-29 16:42:25 +00:00
|
|
|
|
2019-02-09 04:23:37 +00:00
|
|
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
signingConfigs {
|
|
|
|
release
|
|
|
|
}
|
|
|
|
|
|
|
|
buildTypes {
|
|
|
|
release {
|
|
|
|
if (project.hasProperty('storeFile')) {
|
|
|
|
signingConfig signingConfigs.release
|
|
|
|
}
|
2015-01-03 07:29:45 +00:00
|
|
|
|
2017-11-10 21:54:31 +00:00
|
|
|
minifyEnabled true
|
|
|
|
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
|
|
|
|
|
2015-01-03 07:29:45 +00:00
|
|
|
buildConfigField "boolean", "DEVELOPER_MODE", "false"
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
debug {
|
2015-02-16 20:45:04 +00:00
|
|
|
applicationIdSuffix ".debug"
|
2018-05-23 18:09:33 +00:00
|
|
|
testCoverageEnabled rootProject.testCoverage
|
2015-01-03 07:29:45 +00:00
|
|
|
|
2020-05-29 19:35:41 +00:00
|
|
|
minifyEnabled false
|
2018-08-27 13:49:13 +00:00
|
|
|
|
2015-01-03 07:29:45 +00:00
|
|
|
buildConfigField "boolean", "DEVELOPER_MODE", "true"
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// Do not abort build if lint finds errors
|
|
|
|
lintOptions {
|
|
|
|
abortOnError false
|
2014-12-19 22:21:09 +00:00
|
|
|
lintConfig file("$rootProject.projectDir/config/lint/lint.xml")
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
packagingOptions {
|
|
|
|
exclude 'META-INF/DEPENDENCIES'
|
|
|
|
exclude 'META-INF/LICENSE'
|
|
|
|
exclude 'META-INF/LICENSE.txt'
|
|
|
|
exclude 'META-INF/NOTICE'
|
|
|
|
exclude 'META-INF/NOTICE.txt'
|
2017-04-29 00:28:33 +00:00
|
|
|
exclude 'META-INF/README'
|
2020-05-26 19:13:43 +00:00
|
|
|
exclude 'META-INF/README.md'
|
|
|
|
exclude 'META-INF/CHANGES'
|
2014-12-20 06:39:08 +00:00
|
|
|
exclude 'LICENSE.txt'
|
2019-01-22 16:16:07 +00:00
|
|
|
exclude 'META-INF/*.kotlin_module'
|
2020-05-26 19:13:43 +00:00
|
|
|
exclude 'META-INF/*.version'
|
|
|
|
exclude 'kotlin/**'
|
2020-10-04 19:51:17 +00:00
|
|
|
exclude 'DebugProbesKt.bin'
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
|
|
|
|
2020-07-14 23:51:13 +00:00
|
|
|
dependenciesInfo {
|
|
|
|
includeInApk = false
|
|
|
|
includeInBundle = false
|
|
|
|
}
|
|
|
|
|
2014-12-19 22:05:58 +00:00
|
|
|
compileOptions {
|
2019-11-13 15:10:14 +00:00
|
|
|
sourceCompatibility javaVersion
|
|
|
|
targetCompatibility javaVersion
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
2018-02-25 00:28:42 +00:00
|
|
|
|
2019-11-17 13:40:57 +00:00
|
|
|
kotlinOptions {
|
|
|
|
jvmTarget = kotlinJvmVersion
|
|
|
|
}
|
|
|
|
|
2018-02-25 00:28:42 +00:00
|
|
|
testOptions {
|
|
|
|
unitTests {
|
|
|
|
includeAndroidResources = true
|
|
|
|
}
|
|
|
|
}
|
2014-12-19 22:05:58 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
if (project.hasProperty('keyAlias')) {
|
|
|
|
android.signingConfigs.release.keyAlias = keyAlias
|
|
|
|
}
|
|
|
|
if (project.hasProperty('keyPassword')) {
|
|
|
|
android.signingConfigs.release.keyPassword = keyPassword
|
|
|
|
}
|
|
|
|
if (project.hasProperty('storeFile')) {
|
|
|
|
android.signingConfigs.release.storeFile = file(storeFile)
|
|
|
|
}
|
|
|
|
if (project.hasProperty('storePassword')) {
|
|
|
|
android.signingConfigs.release.storePassword = storePassword
|
|
|
|
}
|