Clean up previous commit.

This commit is contained in:
Valentin Lorentz 2018-01-13 00:08:22 +01:00
parent b6af3baf6d
commit 64f27eff74
1 changed files with 3 additions and 8 deletions

View File

@ -56,14 +56,9 @@ try:
stdout=subprocess.PIPE, stderr=subprocess.PIPE) stdout=subprocess.PIPE, stderr=subprocess.PIPE)
date = proc.stdout.readline() date = proc.stdout.readline()
if sys.version_info[0] >= 3: if sys.version_info[0] >= 3:
sdate = date.decode().strip() date = date.decode()
else: version = ".".join(str(i).zfill(2) for i in
sdate = date.strip() time.strptime(time.asctime(time.gmtime(int(date.strip()))))[:3])
idate = int(sdate)
ldate = []
for i in time.strptime(time.asctime(time.gmtime(idate)))[:3]:
ldate.append(str(i).zfill(2))
version = ".".join(ldate)
except: except:
if os.path.isfile(VERSION_FILE): if os.path.isfile(VERSION_FILE):
from src.version import version from src.version import version