aboutsummaryrefslogtreecommitdiff
path: root/sample
diff options
context:
space:
mode:
Diffstat (limited to 'sample')
-rw-r--r--sample/build.gradle24
1 files changed, 14 insertions, 10 deletions
diff --git a/sample/build.gradle b/sample/build.gradle
index 6fdf24a..3350b3b 100644
--- a/sample/build.gradle
+++ b/sample/build.gradle
@@ -38,24 +38,28 @@ android {
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
- signingConfigs {
+ def releaseSigning = file("../files/kau.properties")
+ def hasSigning = releaseSigning.exists()
- def releaseProps = new Properties()
- file("../files/kau.properties").withInputStream { releaseProps.load(it) }
+ if (hasSigning) {
+ signingConfigs {
- release {
- storeFile file("../files/kau.keystore")
- storePassword releaseProps.getProperty('storePassword')
- keyAlias releaseProps.getProperty('keyAlias')
- keyPassword releaseProps.getProperty('keyPassword')
- }
+ def releaseProps = new Properties()
+ releaseSigning.withInputStream { releaseProps.load(it) }
+ release {
+ storeFile file("../files/kau.keystore")
+ storePassword releaseProps.getProperty('storePassword')
+ keyAlias releaseProps.getProperty('keyAlias')
+ keyPassword releaseProps.getProperty('keyPassword')
+ }
+ }
}
buildTypes {
release {
minifyEnabled true
- signingConfig signingConfigs.release
+ if (hasSigning) signingConfig signingConfigs.release
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}