diff --git a/klippy/util.py b/klippy/util.py index a8add833..03c2083d 100644 --- a/klippy/util.py +++ b/klippy/util.py @@ -57,7 +57,7 @@ def get_git_version(): if not os.path.exists(gitdir): logging.debug("No '.git' file/directory found") return "?" - prog = "git -C %s describe --tags --long --dirty" % (gitdir,) + prog = "git -C %s describe --always --tags --long --dirty" % (gitdir,) try: process = subprocess.Popen(shlex.split(prog), stdout=subprocess.PIPE) output = process.communicate()[0] diff --git a/scripts/buildcommands.py b/scripts/buildcommands.py index b9d89e0e..e73bd1c7 100644 --- a/scripts/buildcommands.py +++ b/scripts/buildcommands.py @@ -244,7 +244,7 @@ def git_version(): if not os.path.exists('.git'): logging.debug("No '.git' file/directory found") return "" - ver = check_output("git describe --tags --long --dirty").strip() + ver = check_output("git describe --always --tags --long --dirty").strip() logging.debug("Got git version: %s" % (repr(ver),)) return ver