Better current branch name fetching

This commit is contained in:
Eden Kirin
2023-09-01 10:19:16 +02:00
parent 826077fbaf
commit 460c422507

View File

@ -16,7 +16,7 @@ commit_file = sys.argv[1]
regex = re.compile("^([A-Z]+-[0-9]+)", re.IGNORECASE)
git_branch_name = subprocess.run(
["git", "rev-parse", "--abbrev-ref", "HEAD"],
["git", "branch", "--show-current"],
stdout=subprocess.PIPE,
encoding="utf-8",
)