From 3a092e64aae769aefa49d05c64ad483d458668dd Mon Sep 17 00:00:00 2001 From: Daniel M Date: Sat, 15 Apr 2023 22:02:21 -0700 Subject: [PATCH] apply release name fix in release version generator script --- .github/workflows/generate_release_version.py | 5 +++-- generate_next_release.py | 4 +++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/generate_release_version.py b/.github/workflows/generate_release_version.py index c5100ee..118e7c1 100644 --- a/.github/workflows/generate_release_version.py +++ b/.github/workflows/generate_release_version.py @@ -1,5 +1,6 @@ -import subprocess import datetime +import re +import subprocess tags_process = subprocess.Popen(["git", "for-each-ref", "--sort=creatordate", "--format", "'%(refname) %(taggerdate)'", "refs/tags"], stdout=subprocess.PIPE) tags = "" @@ -17,6 +18,6 @@ continue time = datetime.datetime.utcnow().strftime("%Y%m%d%H%M%S") + tag = re.sub(r"\+\d+", "", tag) print(f"{tag}+{time}") break - diff --git a/generate_next_release.py b/generate_next_release.py index 3fef809..118e7c1 100644 --- a/generate_next_release.py +++ b/generate_next_release.py @@ -1,5 +1,6 @@ -import subprocess import datetime +import re +import subprocess tags_process = subprocess.Popen(["git", "for-each-ref", "--sort=creatordate", "--format", "'%(refname) %(taggerdate)'", "refs/tags"], stdout=subprocess.PIPE) tags = "" @@ -17,5 +18,6 @@ continue time = datetime.datetime.utcnow().strftime("%Y%m%d%H%M%S") + tag = re.sub(r"\+\d+", "", tag) print(f"{tag}+{time}") break