Windows symlink: wrap tempfile.mkdtemp() to long path func

This commit is contained in:
Dmitry Petrov
2017-04-10 12:20:06 -07:00
parent f628c28d3d
commit f539fa8c60
5 changed files with 12 additions and 7 deletions
+4 -2
View File
@@ -54,9 +54,8 @@ class GitWrapperI(object):
LONG_PATH_BUFFER_SIZE = 1024
@staticmethod
def get_cwd():
def get_long_path(path):
"""Convert short path to a full path. It is needed for Windows."""
path = os.getcwd()
if os.name != 'nt':
return path
@@ -67,6 +66,9 @@ class GitWrapperI(object):
return path
return buffer.value
@staticmethod
def get_cwd():
return GitWrapperI.get_long_path(os.getcwd())
@staticmethod
def parse_porcelain_files(out):