Mercurial > public > develkit
diff init40-git.gradle @ 300:eaed73a5ec1d
add println for bamboo debugging
author | Marc Davis <davis@ssdt-ohio.org> |
---|---|
date | Wed, 01 Feb 2023 08:03:29 -0500 |
parents | 5e9e2ea82657 |
children | 74d939ce70d5 |
line wrap: on
line diff
--- a/init40-git.gradle Tue Jan 31 16:01:00 2023 -0500 +++ b/init40-git.gradle Wed Feb 01 08:03:29 2023 -0500 @@ -799,19 +799,21 @@ new BigInteger(1, digest.digest()).toString(16).padLeft(32, '0') } - private findSnapshotVersion() { + private Version findSnapshotVersion() { println "findSnapshotVersion()" try { def repositoryUrl = System.getenv('bamboo_planRepository_repositoryUrl') if (repositoryUrl) { println "git pull $repositoryUrl".execute().text } + println "git tag".execute().text def versions = "git tag".execute().text.split("\n") .collect { it.replace("v", "") } .collect { new Version(*it.split('\\.')*.toInteger()) } .sort { v1, v2 -> v2 <=> v1 } return versions ? versions.first().nextSnapshot() : new Version().nextSnapshot() - } catch (ignored) { + } catch (ex) { + println ex return new Version().nextSnapshot() } }