mirror of
https://github.com/ViaVersion/ViaFabric.git
synced 2025-03-02 03:41:02 +01:00
try to fix cf
This commit is contained in:
parent
d29d8235db
commit
aa322427e1
@ -14,14 +14,14 @@ val gitVersion: groovy.lang.Closure<String> by extra
|
||||
val versionDetails: groovy.lang.Closure<com.palantir.gradle.gitversion.VersionDetails> by extra
|
||||
|
||||
val githubShaInfo: String? = System.getenv("GITHUB_SHA")?.substring(0, 10) // version details doesn't work on gh actions
|
||||
val branch = if (!githubShaInfo.isNullOrBlank()) githubShaInfo else try {
|
||||
val branch = try {
|
||||
versionDetails().branchName
|
||||
} catch (e: Exception) {
|
||||
"unknown"
|
||||
}
|
||||
|
||||
version = "0.3.1-SNAPSHOT+" + try {
|
||||
gitVersion() + "-" + branch
|
||||
(githubShaInfo ?: gitVersion()) + "-" + branch
|
||||
} catch (e: Exception) {
|
||||
"unknown"
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user