Windows: fix version detection from git (@karpierz)

This commit is contained in:
Pierre LALET 2018-01-12 10:47:49 +01:00
parent a995f0f87f
commit 7609110c18
1 changed files with 1 additions and 1 deletions

View File

@ -38,7 +38,7 @@ def _version_from_git_describe():
>>> _version_from_git_describe() >>> _version_from_git_describe()
'2.3.2.dev346' '2.3.2.dev346'
""" """
if not os.path.isdir(os.path.join(_SCAPY_PKG_DIR, '../.git')): if not os.path.isdir(os.path.join(os.path.dirname(_SCAPY_PKG_DIR), '.git')):
raise ValueError('not in scapy git repo') raise ValueError('not in scapy git repo')
p = subprocess.Popen(['git', 'describe', '--always'], cwd=_SCAPY_PKG_DIR, p = subprocess.Popen(['git', 'describe', '--always'], cwd=_SCAPY_PKG_DIR,