Commit 0dd6bca4 authored by w-e-w's avatar w-e-w

fallback version info form CHANGELOG.md

parent 3e995778
......@@ -68,7 +68,8 @@ def git_tag():
try:
return subprocess.check_output([git, "describe", "--tags"], shell=False, encoding='utf8').strip()
except Exception:
return "<none>"
with open(os.path.dirname(os.path.abspath(__file__)) + "/../CHANGELOG.md") as file:
return next((line.strip() for line in file if line.strip()), "<none>")
def run(command, desc=None, errdesc=None, custom_env=None, live: bool = default_command_live) -> str:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment