File input-remapper_commit.patch of Package input-remapper
diff --git a/setup.py b/setup.py
index 20c7d3c..65a2baf 100644
--- a/setup.py
+++ b/setup.py
@@ -35,17 +35,6 @@ class Install(install):
"""Add the commit hash and build .mo translations."""
def run(self):
- try:
- commit = os.popen("git rev-parse HEAD").read().strip()
- if re.match(r"^([a-z]|[0-9])+$", commit):
- # for whatever reason different systems have different paths here
- build_dir = ""
- if os.path.exists("build/lib/inputremapper"):
- build_dir = "build/lib/"
- with open(f"{build_dir}inputremapper/commit_hash.py", "w+") as f:
- f.write(f"COMMIT_HASH = '{commit}'\n")
- except Exception as e:
- print("Failed to save the commit hash:", e)
# generate .mo files
make_lang()