1
0
Fork 0
mirror of https://github.com/gsantner/dandelion synced 2024-11-01 01:56:01 +01:00
dandelion/app/build.gradle

137 lines
4.7 KiB
Groovy
Raw Normal View History

2016-03-03 17:46:31 +01:00
apply plugin: 'com.android.application'
2017-11-18 20:04:59 +01:00
if (enable_plugin_kotlin) {
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'kotlin-kapt'
2017-08-04 05:42:43 +02:00
}
2016-03-03 17:46:31 +01:00
android {
2019-01-11 02:38:30 +01:00
buildToolsVersion rootProject.ext.version_buildTools
compileSdkVersion rootProject.ext.version_compileSdk
2016-03-03 17:46:31 +01:00
defaultConfig {
resValue "string", "manifest_package_id", "com.github.dfa.diaspora_android"
applicationId "com.github.dfa.diaspora_android"
2020-12-09 12:08:05 +01:00
versionName "1.3.5"
versionCode 46
vectorDrawables.useSupportLibrary = true
2019-01-11 02:38:30 +01:00
minSdkVersion rootProject.ext.version_minSdk
targetSdkVersion rootProject.ext.version_compileSdk
2017-10-29 11:01:27 +01:00
buildConfigField "boolean", "IS_TEST_BUILD", "false"
buildConfigField "boolean", "IS_GPLAY_BUILD", "false"
2018-03-05 23:37:24 +01:00
buildConfigField "String[]", "DETECTED_ANDROID_LOCALES", "${findUsedAndroidLocales()}"
buildConfigField "String", "BUILD_DATE", "\"${getBuildDate()}\""
2017-10-29 11:01:27 +01:00
buildConfigField "String", "GITHASH", "\"${getGitHash()}\""
setProperty("archivesBaseName", applicationId + "-v" + versionCode + "-" + versionName)
2017-10-29 11:01:27 +01:00
}
2017-05-03 23:48:22 +02:00
2019-01-11 02:38:30 +01:00
flavorDimensions "default"
2016-12-22 04:07:30 +01:00
productFlavors {
flavorDefault {
2016-12-22 04:07:30 +01:00
}
/*
2017-11-18 20:04:59 +01:00
flavorGplay {
2017-05-03 23:48:22 +02:00
buildConfigField "boolean", "IS_GPLAY_BUILD", "true"
2017-10-29 11:01:27 +01:00
}*/
2018-03-05 23:37:24 +01:00
flavorDandelior {
applicationId "net.gsantner.dandelior"
}
flavorAtest {
applicationId "net.gsantner.secondlion"
2017-02-24 22:46:17 +01:00
versionCode = Integer.parseInt(new Date().format('yyMMdd'))
versionName = new Date().format('yyMMdd')
buildConfigField "boolean", "IS_TEST_BUILD", "true"
2016-12-22 04:07:30 +01:00
}
}
2019-01-11 02:38:30 +01:00
sourceSets {
main { assets.srcDirs = ['src/main/assets'] }
if (enable_plugin_kotlin) {
main.java.srcDirs += 'src/main/kotlin'
}
main.java.srcDirs += 'thirdparty/java'
main.res.srcDirs += 'thirdparty/res'
main.assets.srcDirs += 'thirdparty/assets'
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
configurations.all {
resolutionStrategy {
eachDependency { details ->
if (details.requested.group == 'com.android.support') {
if (details.requested.name != 'multidex' && details.requested.name != 'multidex-instrumentation') {
details.useVersion "${rootProject.ext.version_library_appcompat}"
}
}
}
}
}
packagingOptions {
exclude 'META-INF/LICENSE-LGPL-2.1.txt'
exclude 'META-INF/LICENSE-LGPL-3.txt'
exclude 'META-INF/LICENSE-W3C-TEST'
}
compileOptions {
encoding = 'UTF-8'
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
2016-07-27 21:54:54 +02:00
lintOptions {
disable 'MissingTranslation', 'InvalidPackage', 'ObsoleteLintCustomCheck', 'DefaultLocale', 'UnusedAttribute', 'VectorRaster', 'InflateParams', 'IconLocation', 'UnusedResources', 'TypographyEllipsis'
2019-01-11 02:38:30 +01:00
abortOnError false
2016-07-27 21:54:54 +02:00
}
2016-03-03 17:46:31 +01:00
}
dependencies {
2016-05-05 17:42:29 +02:00
// Sub-Projects
2017-10-29 11:01:27 +01:00
//implementation project(':subprojectFromRoot')
2016-05-05 17:42:29 +02:00
// Jars
2017-10-29 11:01:27 +01:00
implementation fileTree(dir: 'libs', include: ['*.jar'])
testImplementation 'junit:junit:4.13'
2016-05-05 17:42:29 +02:00
// Android standard libs
2017-11-18 20:04:59 +01:00
implementation "com.android.support:appcompat-v7:${version_library_appcompat}"
implementation "com.android.support:design:${version_library_appcompat}"
implementation "com.android.support:support-v4:${version_library_appcompat}"
implementation "com.android.support:customtabs:${version_library_appcompat}"
implementation "com.android.support:cardview-v7:${version_library_appcompat}"
2019-07-26 03:19:28 +02:00
implementation "com.android.support:preference-v7:${version_library_appcompat}"
2016-05-05 17:42:29 +02:00
// UI libraries
2017-10-29 11:01:27 +01:00
implementation "com.github.DASAR:ShiftColorPicker:v0.5"
// Tool libraries
2019-07-26 03:19:28 +02:00
implementation 'commons-io:commons-io:2.6'
2017-11-18 20:04:59 +01:00
implementation "info.guardianproject.netcipher:netcipher:${version_library_netcipher}"
implementation "info.guardianproject.netcipher:netcipher-webkit:${version_library_netcipher}"
//noinspection AnnotationProcessorOnCompilePath
2017-11-18 20:04:59 +01:00
implementation "com.jakewharton:butterknife:${version_library_butterknife}"
if (enable_plugin_kotlin) {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:${version_plugin_kotlin}"
2017-11-18 20:04:59 +01:00
}
2017-08-04 05:42:43 +02:00
2017-11-18 20:04:59 +01:00
// Processors
def anpros = ["com.jakewharton:butterknife-compiler:${version_library_butterknife}"]
for (anpro in anpros) {
if (enable_plugin_kotlin) {
kapt anpro
} else {
annotationProcessor anpro
}
}
}