Fix detection of Limnoria version from Git when running the setup with Python 3.

This commit is contained in:
Valentin Lorentz 2013-10-27 11:43:21 +01:00
parent b6ea53b07a
commit 4aa34ba6d8
1 changed files with 4 additions and 1 deletions

View File

@ -47,7 +47,10 @@ version = None
try:
proc = subprocess.Popen('git show HEAD --format=%ci', shell=True,
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
version = proc.stdout.readline() \
version = proc.stdout.readline()
if sys.version_info[0] >= 3:
version = version.decode()
version = version \
.strip() \
.split(' +')[0] \
.replace(' ', 'T') \