Fix missing path component in utils.py
This commit is contained in:
2
util.py
2
util.py
@@ -39,7 +39,7 @@ def findGitVersion():
|
|||||||
with open(os.path.join(this_dir,".git","HEAD")) as f:
|
with open(os.path.join(this_dir,".git","HEAD")) as f:
|
||||||
data = f.read().strip()
|
data = f.read().strip()
|
||||||
if data.startswith("ref: "):
|
if data.startswith("ref: "):
|
||||||
if not os.path.exists(os.path.join(this_dir,data[5:])):
|
if not os.path.exists(os.path.join(this_dir, ".git", data[5:])):
|
||||||
return data
|
return data
|
||||||
with open(os.path.join(this_dir, ".git", data[5:])) as g:
|
with open(os.path.join(this_dir, ".git", data[5:])) as g:
|
||||||
return g.read().strip()
|
return g.read().strip()
|
||||||
|
|||||||
Reference in New Issue
Block a user