aboutsummaryrefslogtreecommitdiff
path: root/app/build.gradle
diff options
context:
space:
mode:
Diffstat (limited to 'app/build.gradle')
-rw-r--r--app/build.gradle33
1 files changed, 22 insertions, 11 deletions
diff --git a/app/build.gradle b/app/build.gradle
index aa5a776e..b4a3a42e 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -43,7 +43,13 @@ android {
textOutput 'stdout'
}
- def withReleaseSigning = file('../files/release.keystore').exists()
+ def testKeystoreFile = file('../files/test.keystore')
+ def testPropFile = file('../files/test.properties')
+ def withTestSigning = testKeystoreFile.exists() && testPropFile.exists()
+
+ def releaseKeystoreFile = file('../files/release.keystore')
+ def releasePropFile = file('../files/release.properties')
+ def withReleaseSigning = releaseKeystoreFile.exists() && releasePropFile.exists()
signingConfigs {
@@ -54,19 +60,24 @@ android {
keyPassword "debugKey"
}
- test {
- storeFile file("../files/test.keystore")
- storePassword "testkey"
- keyAlias "testKey"
- keyPassword "testkey"
+ if (withTestSigning) {
+ def testProps = new Properties()
+ testPropFile.withInputStream { testProps.load(it) }
+
+ test {
+ storeFile testKeystoreFile
+ storePassword testProps.getProperty('storePassword')
+ keyAlias testProps.getProperty('keyAlias')
+ keyPassword testProps.getProperty('keyPassword')
+ }
}
if (withReleaseSigning) {
def releaseProps = new Properties()
- file("../files/release.properties").withInputStream { releaseProps.load(it) }
+ releasePropFile.withInputStream { releaseProps.load(it) }
release {
- storeFile file("../files/release.keystore")
+ storeFile releaseKeystoreFile
storePassword releaseProps.getProperty('storePassword')
keyAlias releaseProps.getProperty('keyAlias')
keyPassword releaseProps.getProperty('keyPassword')
@@ -92,7 +103,7 @@ android {
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
applicationIdSuffix ".test"
versionNameSuffix "-test"
- signingConfig signingConfigs.test
+ if (withTestSigning) signingConfig signingConfigs.test
resValue "string", "frost_name", "Frost Test"
resValue "string", "frost_web", "Frost Web Test"
}
@@ -159,14 +170,14 @@ dependencies {
implementation "com.devbrackets.android:exomedia:${EXOMEDIA}"
- implementation"com.mikepenz:fastadapter-extensions:${kau.fastAdapter}@aar"
+ implementation "com.mikepenz:fastadapter-extensions:${kau.fastAdapter}@aar"
//noinspection GradleDependency
implementation "com.github.bumptech.glide:okhttp3-integration:${kau.glide}"
//noinspection GradleDependency
kapt "com.github.bumptech.glide:compiler:${kau.glide}"
- implementation "com.fasterxml.jackson.core:jackson-databind:2.9.3"
+ implementation "com.fasterxml.jackson.core:jackson-databind:${JACKSON}"
//noinspection GradleDependency
releaseImplementation "com.squareup.leakcanary:leakcanary-android-no-op:${LEAK_CANARY}"