From 47b06f08a7bd86b3158d1f7182d9249299809c89 Mon Sep 17 00:00:00 2001 From: Elliot Berman Date: Sun, 17 Feb 2019 14:07:28 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=A4=A6=E2=80=8D=E2=99=80=EF=B8=8F=20Dot?= =?UTF-8?q?=20between=20build=20ID=20and=20commit=20on=20Azure=20Pipelines?= =?UTF-8?q?=20(#113)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #### Summary: Need a "." between build number and commit, not a plus #### Motivation: Use non-tagged templates built by Azure ##### References (optional): purduesigbots/pros-cli#66 purduesigbots/pros-cli#64 #### Test Plan: - [x] Can fetch/use template built locally - [x] Can fetch/use template built on Azure #### Commits: * dot between build number and commit * Dots are better in general --- version.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/version.py b/version.py index ade03af0e..e818f25ec 100644 --- a/version.py +++ b/version.py @@ -16,8 +16,8 @@ # pippre = 'alpha' if v.endswith('-dirty') else 'pre' build = subprocess.check_output(['git', 'rev-parse', '--short', 'HEAD']).decode().strip() number_since = subprocess.check_output(['git', 'rev-list', v[:v.index('-')] + '..HEAD', '--count']).decode().strip() - build = "{}+{}".format(number_since, build) - semver = bv + '-' + sempre + '+' + build + build = "{}.{}".format(number_since, build) + semver = bv + '-' + sempre + '.' + build else: semver = v