Fix flake8 error

This commit is contained in:
Shane McDonald
2017-07-24 15:12:24 -04:00
parent deb8eaa982
commit 1b2d0f9683

View File

@@ -24,6 +24,7 @@ if os.getenv('OFFICIAL', 'no') == 'yes':
else:
build_tag = '-' + '0.git' + subprocess.Popen("git describe --long | cut -d - -f 2-2", shell=True, stdout=subprocess.PIPE).stdout.read().strip()
def get_version():
ver = subprocess.Popen("git describe --long | cut -f1-1 -d -", shell=True, stdout=subprocess.PIPE).stdout.read().strip()
return re.sub(r'-([0-9]+)-.*', r'.\1', ver)