From d1f5986e393e0010cdcc5c1a25ffbca8e1998836 Mon Sep 17 00:00:00 2001 From: Torsten Grote Date: Mon, 3 Jun 2019 15:51:58 -0300 Subject: [PATCH] Add signing config for faster testing --- .gitignore | 1 + app/build.gradle | 17 +++++++++++++++++ 2 files changed, 18 insertions(+) diff --git a/.gitignore b/.gitignore index f625d6f8..57157126 100644 --- a/.gitignore +++ b/.gitignore @@ -39,6 +39,7 @@ nb-configuration.xml ## Gradle .gradle +keystore.properties gradle-app.setting ## OS Specific diff --git a/app/build.gradle b/app/build.gradle index 4a39d833..3e495edf 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -25,6 +25,23 @@ android { targetCompatibility 1.8 sourceCompatibility 1.8 } + + // optional signingConfigs + def keystorePropertiesFile = rootProject.file("keystore.properties") + if (keystorePropertiesFile.exists()) { + def keystoreProperties = new Properties() + keystoreProperties.load(new FileInputStream(keystorePropertiesFile)) + + signingConfigs { + release { + keyAlias keystoreProperties['keyAlias'] + keyPassword keystoreProperties['keyPassword'] + storeFile file(keystoreProperties['storeFile']) + storePassword keystoreProperties['storePassword'] + } + } + buildTypes.release.signingConfig = signingConfigs.release + } } gradle.projectsEvaluated {