File tree Expand file tree Collapse file tree 1 file changed +5
-21
lines changed
Expand file tree Collapse file tree 1 file changed +5
-21
lines changed Original file line number Diff line number Diff line change 1+ import org.mangorage.mangobotgradle.util.GitVersion
2+
3+
14buildscript {
25 repositories {
36 mavenLocal()
@@ -15,7 +18,7 @@ buildscript {
1518
1619 dependencies {
1720 classpath ' gradle.plugin.com.github.johnrengelman:shadow:7.1.2'
18- classpath ' org.mangorage:MangoBotGradle:5.0.2 '
21+ classpath ' org.mangorage:MangoBotGradle:5.0.4 '
1922 }
2023}
2124
@@ -25,26 +28,7 @@ apply plugin: 'MangoBotGradle'
2528apply plugin : ' maven-publish'
2629
2730group = ' org.mangorage'
28- version = getLatestGitTag() + " ." + getLatestGitVersion()
29-
30- def getLatestGitTag () {
31- def result = " git describe --long --tags" . execute(). text. trim()
32- if (result. empty) {
33- throw new RuntimeException (" Failed to retrieve commit count" )
34- } else {
35- return result. split(" -" )[0 ]
36- }
37- }
38-
39- def getLatestGitVersion () {
40- def result = " git describe --long --tags" . execute(). text. trim()
41- if (result. empty) {
42- throw new RuntimeException (" Failed to retrieve commit count" )
43- } else {
44- def commitCount = result. split(" -" )[1 ]. toInteger()
45- return commitCount;
46- }
47- }
31+ version = GitVersion . getGitVersion(). getVersionAsString()
4832
4933println (" Version: " + version)
5034
You can’t perform that action at this time.
0 commit comments