Skip to content

Commit

Permalink
Simplified get version
Browse files Browse the repository at this point in the history
  • Loading branch information
hannesa2 committed Oct 13, 2024
1 parent c3f71c4 commit ec4648d
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions android/mainSample/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -67,18 +67,8 @@ dependencies {
}

static def getTag() {
def tagVersion = "$System.env.TAG_VERSION"
if (tagVersion == "null") {
println "No variable TAG_VERSION specified, I'm using 'git describe --abbrev=0'"
def process = "git describe --abbrev=0".execute()
tagVersion = process.text.toString().trim()
if (tagVersion.equals("")) {
println "abbrev failed, I'm using 'git --tags'"
def processT = "git describe --tags".execute()
tagVersion = processT.text.toString().trim()
}
}
return tagVersion
def process = "git describe --tags --abbrev=0".execute()
return process.text.toString().trim()
}

static def getGitCommitCount() {
Expand Down

0 comments on commit ec4648d

Please sign in to comment.