aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/buildcommands.py
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/buildcommands.py')
-rw-r--r--scripts/buildcommands.py12
1 files changed, 2 insertions, 10 deletions
diff --git a/scripts/buildcommands.py b/scripts/buildcommands.py
index fa4303ed..a9043394 100644
--- a/scripts/buildcommands.py
+++ b/scripts/buildcommands.py
@@ -8,6 +8,7 @@ import sys, os, subprocess, optparse, logging, shlex, socket, time, traceback
import json, zlib
sys.path.append("./klippy")
+import klippy.klippy
import msgproto
FILEHEADER = """
@@ -555,18 +556,9 @@ def check_output(prog):
return ""
-# Obtain version info from "git" program
-def git_version():
- if not os.path.exists(".git"):
- logging.debug("No '.git' file/directory found")
- return ""
- ver = check_output("git describe --always --tags --long --dirty").strip()
- logging.debug("Got git version: %s" % (repr(ver),))
- return ver
-
def build_version(extra, cleanbuild):
- version = git_version()
+ version = klippy.klippy.__version__
if not version:
cleanbuild = False
version = "?"