Skip to content

Commit

Permalink
Fix version naming when alpha/beta-versions are used (#81)
Browse files Browse the repository at this point in the history
* launch CI (website, release) on correct release operation

* trigger release assets action on published

* trigger release actions on edited and published

* corrected naming for jars (consider hyphen in alpha or beta versions)

* add --first-parent option to version naming based on git describe
  • Loading branch information
michaelhglass authored May 4, 2021
1 parent 41c728e commit 9f5a5a3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ def getVersionName = {
->
def stdout = new ByteArrayOutputStream()
exec {
commandLine 'git', 'describe', '--tags'
commandLine 'git', 'describe', '--tags', '--first-parent'
standardOutput = stdout
ignoreExitValue true
}
version=stdout.toString().trim()
if (version.indexOf('-') >= 0 || version.isEmpty())
if (version.count('-') > 1 || version.isEmpty())
version += '-SNAPSHOT'
return version
}
Expand Down

0 comments on commit 9f5a5a3

Please sign in to comment.