Try to fix dirty

This commit is contained in:
frknkrc44 2025-08-27 01:54:12 +03:00
commit d96a91b46e
No known key found for this signature in database
GPG key ID: 784AE1CC0DCFD34F

View file

@ -17,7 +17,13 @@ fun String.execute(currentWorkingDir: File = file("./")): String {
return out.standardOutput.asText.get().trim()
}
val localProperties = Properties()
localProperties.load(file("local.properties").inputStream())
val officialBuild by extra(localProperties.getProperty("officialBuild", "false") == "true")
fun getUncommittedSuffix(): String {
if (officialBuild) return ""
val result = "git status -s".execute()
if (result.isEmpty()) {
return ""
@ -43,10 +49,6 @@ val minBackupVerCode by extra(65)
val androidSourceCompatibility = JavaVersion.VERSION_21
val androidTargetCompatibility = JavaVersion.VERSION_21
val localProperties = Properties()
localProperties.load(file("local.properties").inputStream())
val officialBuild by extra(localProperties.getProperty("officialBuild", "false") == "true")
tasks.register("clean", Delete::class) {
delete(rootProject.layout.buildDirectory)
}