mirror of
https://github.com/Xiao-MoMi/Custom-Fishing.git
synced 2025-12-19 15:09:24 +00:00
Update build.gradle.kts
This commit is contained in:
@@ -37,9 +37,13 @@ subprojects {
|
||||
|
||||
fun versionBanner(): String {
|
||||
val os = ByteArrayOutputStream()
|
||||
project.exec {
|
||||
commandLine = "git rev-parse --short=8 HEAD".split(" ")
|
||||
standardOutput = os
|
||||
try {
|
||||
project.exec {
|
||||
commandLine = "git rev-parse --short=8 HEAD".split(" ")
|
||||
standardOutput = os
|
||||
}
|
||||
} catch (e: ExecException) {
|
||||
return "Unknown"
|
||||
}
|
||||
return String(os.toByteArray()).trim()
|
||||
}
|
||||
@@ -51,7 +55,7 @@ fun builder(): String {
|
||||
commandLine = "git config user.name".split(" ")
|
||||
standardOutput = os
|
||||
}
|
||||
} catch (e: Exception) {
|
||||
} catch (e: ExecException) {
|
||||
return "Unknown"
|
||||
}
|
||||
return String(os.toByteArray()).trim()
|
||||
|
||||
Reference in New Issue
Block a user