S88 Calibration log V3.1.9

This commit is contained in:
Gingerman1996 committed 2025-01-06 13:50:28 +07:00
1 parent c841476ca4
commit 4691500f5f
4 files changed
+70 -16

No files matched your search

+18
View File
@@ -0,0 +1,18 @@
import subprocess
import os
def get_git_version():
try:
version = subprocess.check_output(["git", "describe", "--tags", "--always", "--dirty"]).decode("utf-8").strip()
return version
except Exception as e:
print("Could not get git version:", e)
return "unknown"
git_version = get_git_version()
# git_version = "0.8.7-1-g118f259-dirty"
print("GIT_VERSION:", git_version)
# เพิ่ม GIT_VERSION เป็น build flag
Import("env")
env.Append(CPPDEFINES=[("GIT_VERSION", '\\"{}\\"'.format(git_version))])