From d42aed877dd3529f625432cad9c080d48b7c6a3b Mon Sep 17 00:00:00 2001 From: Phillip Thelen Date: Tue, 10 May 2016 12:43:30 +0200 Subject: [PATCH] try speeding up gradle builds --- Habitica/build.gradle | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/Habitica/build.gradle b/Habitica/build.gradle index 67458a0a6..713b64922 100644 --- a/Habitica/build.gradle +++ b/Habitica/build.gradle @@ -151,6 +151,15 @@ android { } } + productFlavors { + dev { + minSdkVersion 21 + } + prod { + minSdkVersion 15 + } + } + sourceSets { main { manifest.srcFile 'AndroidManifest.xml' @@ -174,6 +183,12 @@ android { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } + + dexOptions { + preDexLibraries true + javaMaxHeapSize "2g" // Use gig increments depending on needs + incremental true + } } def Properties props = new Properties() @@ -215,6 +230,12 @@ if (HRPG_PROPS_FILE.canRead()) { throw new MissingResourceException('habitica.properties not found') } +tasks.whenTaskAdded { task -> + if (task.name.equals("lint")) { + task.enabled = false + } +} + apply plugin: 'com.getkeepsafe.dexcount' apply plugin: 'com.android.application' //or apply plugin: 'java' -apply plugin: 'me.tatarka.retrolambda' \ No newline at end of file +apply plugin: 'me.tatarka.retrolambda'