From 2e38cf3a40abb7ad18ea58b61c12450e69ab84fa Mon Sep 17 00:00:00 2001 From: orionlee Date: Thu, 3 May 2018 14:00:48 -0700 Subject: [PATCH] Build tweak: Speed up debug build by making dexcount optional in debug build, configured with a new gradle property enableDexcountInDebug. --- app/build.gradle | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/app/build.gradle b/app/build.gradle index e4f66fe64..0efe9df73 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -83,7 +83,14 @@ android { applicationIdSuffix ".debug" resValue "string", "provider_authority", "de.danoeh.antennapod.debug.provider" buildConfigField STRING, FLATTR_APP_KEY, mFlattrAppKey - buildConfigField STRING, FLATTR_APP_SECRET, mFlattrAppSecret + buildConfigField STRING, FLATTR_APP_SECRET, mFlattrAppSecret + dexcount { + // Optionally, can disable Dexcount by setting the property + // in gradle.properties file or via -P command line argument. + if (project.hasProperty("enableDexcountInDebug")) { + runOnEachPackage enableDexcountInDebug.toBoolean() + } // else default to true + } } release { resValue "string", "provider_authority", "de.danoeh.antennapod.provider"