From 00a5d5ff64fdb23c86bbbc3286297a5c2a8bacd0 Mon Sep 17 00:00:00 2001 From: dordsor21 Date: Wed, 2 Jan 2019 13:01:37 +0000 Subject: [PATCH] Nicer versioning and match CI build number --- build.gradle | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/build.gradle b/build.gradle index 8e2fdcf5d..b74686220 100644 --- a/build.gradle +++ b/build.gradle @@ -32,14 +32,15 @@ ext { date = git.head().getDate().format("yy.MM.dd") revision = "-${git.head().abbreviatedId}" parents = git.head().parentIds; - index = 0; // Offset to match CI + index = -2048; // Offset to match CI for (; parents != null && !parents.isEmpty(); index++) { parents = git.getResolve().toCommit(parents.get(0)).getParentIds() } - buildNumber = "-${index}" + buildNumber = "${index}" } -version = String.format("%s.%s%s%s", rootVersion, date, revision, buildNumber) +// version = String.format("%s.%s%s%s", rootVersion, date, revision, buildNumber) +version = String.format("%s.%s", rootVersion, buildNumber) description = rootProject.name if (project.hasProperty("lzNoVersion")) { // gradle build -PlzNoVersion