Get ready for nightlies
This commit is contained in:
6
.gitignore
vendored
6
.gitignore
vendored
@@ -41,3 +41,9 @@ gradle-app.setting
|
||||
app/release/*
|
||||
app/beta/*
|
||||
app/alpha/*
|
||||
app/nightly/*
|
||||
|
||||
|
||||
#Exclude signing configurations & keystore
|
||||
signing.properties
|
||||
*.keystore
|
||||
|
||||
@@ -38,11 +38,16 @@ android {
|
||||
multiDexEnabled true
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
release
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled true
|
||||
shrinkResources true
|
||||
zipAlignEnabled true
|
||||
signingConfig signingConfigs.release
|
||||
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||
}
|
||||
|
||||
@@ -51,6 +56,11 @@ android {
|
||||
applicationIdSuffix = ".beta"
|
||||
}
|
||||
|
||||
nightly {
|
||||
initWith release
|
||||
applicationIdSuffix = ".nightly"
|
||||
}
|
||||
|
||||
debug {
|
||||
applicationIdSuffix = ".debug"
|
||||
}
|
||||
@@ -163,4 +173,24 @@ dependencies {
|
||||
|
||||
//Love <3
|
||||
api("com.gitlab.AuroraOSS:gplayapi:514f061739")
|
||||
}
|
||||
|
||||
Properties props = new Properties()
|
||||
def propFile = new File("signing.properties")
|
||||
if (propFile.canRead()) {
|
||||
props.load(new FileInputStream(propFile))
|
||||
|
||||
if (props != null && props.containsKey("STORE_FILE") && props.containsKey("STORE_PASSWORD") &&
|
||||
props.containsKey("KEY_ALIAS") && props.containsKey("KEY_PASSWORD")) {
|
||||
android.signingConfigs.release.storeFile = file(props["STORE_FILE"])
|
||||
android.signingConfigs.release.storePassword = props["STORE_PASSWORD"]
|
||||
android.signingConfigs.release.keyAlias = props["KEY_ALIAS"]
|
||||
android.signingConfigs.release.keyPassword = props["KEY_PASSWORD"]
|
||||
} else {
|
||||
println "signing.properties found but some entries are missing"
|
||||
android.buildTypes.release.signingConfig = null
|
||||
}
|
||||
} else {
|
||||
println "signing.properties not found"
|
||||
android.buildTypes.release.signingConfig = null
|
||||
}
|
||||
Reference in New Issue
Block a user