Change certificat configuration for debug
This commit is contained in:
parent
d09b16ee33
commit
de0fc464a4
5 changed files with 34 additions and 29 deletions
|
|
@ -1,5 +1,3 @@
|
|||
import com.android.build.gradle.internal.dsl.SigningConfig
|
||||
|
||||
plugins {
|
||||
id("com.android.application")
|
||||
id("org.jetbrains.kotlin.android")
|
||||
|
|
@ -14,11 +12,17 @@ android {
|
|||
compileSdk = 33
|
||||
|
||||
signingConfigs {
|
||||
getByName("debug") {
|
||||
storeFile = file("../debug.keystore")
|
||||
storePassword = "123456"
|
||||
keyAlias = "debug"
|
||||
keyPassword = "123456"
|
||||
}
|
||||
create("pixelized") {
|
||||
storeFile = file(project.properties["PIXELIZED_RELEASE_STORE_FILE"] as String)
|
||||
storePassword = project.properties["PIXELIZED_RELEASE_STORE_PASSWORD"] as String
|
||||
keyAlias = project.properties["PIXELIZED_RELEASE_KEY_ALIAS"] as String
|
||||
keyPassword = project.properties["PIXELIZED_RELEASE_KEY_PASSWORD"] as String
|
||||
storeFile = (project.properties["PIXELIZED_RELEASE_STORE_FILE"] as? String)?.let { file(it) }
|
||||
storePassword = project.properties["PIXELIZED_RELEASE_STORE_PASSWORD"] as? String
|
||||
keyAlias = project.properties["PIXELIZED_RELEASE_KEY_ALIAS"] as? String
|
||||
keyPassword = project.properties["PIXELIZED_RELEASE_KEY_PASSWORD"] as? String
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -36,19 +40,19 @@ android {
|
|||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
isDebuggable = false
|
||||
isMinifyEnabled = true
|
||||
signingConfig = signingConfigs.pixelized
|
||||
proguardFiles(
|
||||
getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro"
|
||||
)
|
||||
}
|
||||
debug {
|
||||
applicationIdSuffix = ".dev"
|
||||
isDebuggable = true
|
||||
isMinifyEnabled = false
|
||||
signingConfig = signingConfigs.pixelized
|
||||
signingConfig = signingConfigs.getByName("debug")
|
||||
proguardFiles(
|
||||
getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro"
|
||||
)
|
||||
}
|
||||
release {
|
||||
isDebuggable = false
|
||||
isMinifyEnabled = true
|
||||
signingConfig = signingConfigs.getByName("pixelized")
|
||||
proguardFiles(
|
||||
getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro"
|
||||
)
|
||||
|
|
@ -126,13 +130,12 @@ dependencies {
|
|||
kapt("com.github.bumptech.glide:compiler:4.14.2") // this have to be align with landscapist-glide
|
||||
}
|
||||
|
||||
private val NamedDomainObjectContainer<SigningConfig>.pixelized get() = this.getByName("pixelized")
|
||||
|
||||
val gitBuildNumber: Int get() {
|
||||
val stdout = org.apache.commons.io.output.ByteArrayOutputStream()
|
||||
rootProject.exec {
|
||||
commandLine("git", "rev-list", "--count", "HEAD")
|
||||
standardOutput = stdout
|
||||
}
|
||||
return stdout.toString().trim().toInt()
|
||||
}
|
||||
val gitBuildNumber: Int
|
||||
get() {
|
||||
val stdout = org.apache.commons.io.output.ByteArrayOutputStream()
|
||||
rootProject.exec {
|
||||
commandLine("git", "rev-list", "--count", "HEAD")
|
||||
standardOutput = stdout
|
||||
}
|
||||
return stdout.toString().trim().toInt()
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue