add last commit hash to nightly build versions
This commit is contained in:
committed by
Aayush Gupta
parent
011ac6127a
commit
f9d6ac6bf8
@@ -34,6 +34,10 @@ plugins {
|
|||||||
alias(libs.plugins.hilt.android.plugin)
|
alias(libs.plugins.hilt.android.plugin)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
val lastCommitHash = providers.exec {
|
||||||
|
commandLine("git", "rev-parse", "--short", "HEAD")
|
||||||
|
}.standardOutput.asText.map { it.trim() }
|
||||||
|
|
||||||
kotlin {
|
kotlin {
|
||||||
jvmToolchain(21)
|
jvmToolchain(21)
|
||||||
}
|
}
|
||||||
@@ -95,6 +99,7 @@ android {
|
|||||||
register("nightly") {
|
register("nightly") {
|
||||||
initWith(getByName("release"))
|
initWith(getByName("release"))
|
||||||
applicationIdSuffix = ".nightly"
|
applicationIdSuffix = ".nightly"
|
||||||
|
versionNameSuffix = "-${lastCommitHash.get()}"
|
||||||
}
|
}
|
||||||
|
|
||||||
debug {
|
debug {
|
||||||
|
|||||||
Reference in New Issue
Block a user