Skip to content

Commit

Permalink
update build.gradle
Browse files Browse the repository at this point in the history
  • Loading branch information
sameersubudhi committed Jan 20, 2025
1 parent 7fac5c3 commit d6bc890
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -301,8 +301,16 @@ jacoco {
}

static def getVersion() {
def exactVersion = 'git describe --tags --exact-match'.execute().text.trim()
def exactVersion = ""
def result = ""

def gitDescribeResponse = 'git describe --tags --exact-match'.execute()
ignoreExitValue true

if (execResult.getExitValue() == 0){
exactVersion = gitDescribeResponse.text.trim()
}

if (exactVersion) {
result = exactVersion
} else {
Expand Down

0 comments on commit d6bc890

Please sign in to comment.