From a5a21a8678dd09ad84d6a626053c415e3637e602 Mon Sep 17 00:00:00 2001 From: GeminiServer Date: Sat, 21 Mar 2020 01:27:55 +0100 Subject: [PATCH] bugfix - git hash returns tags (if set) instead the short hash using "git rev-parse --short=7 HEAD" to be sure we always get the commit hash. --- Translation Editor/make_translation.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Translation Editor/make_translation.py b/Translation Editor/make_translation.py index a33650d6..c777cb63 100755 --- a/Translation Editor/make_translation.py +++ b/Translation Editor/make_translation.py @@ -503,7 +503,8 @@ def readVersion(): if line: version = line[0] try: version += "."+ subprocess.check_output( - ["git","describe", "--always"]).strip().decode('ascii').upper() + ["git","rev-parse", "--short=7", "HEAD"]).strip().decode('ascii').upper() + # --short=7: the shorted hash with 7 digits. Increase/decrease if needed! except OSError: version += " git" finally: if version_file: