feat(bin/linja): enforce path separator '\' on Windows platform

This commit is contained in:
Soonho Kong 2014-10-03 17:28:00 -07:00
parent b9e7fecb1f
commit f8164b6a7e

View file

@ -21,6 +21,12 @@ import tempfile
import threading
import urllib
# Fixate the path separator as '\' on Windows Platform
# even if users are on CYGWIN/MSYS2 environment
if platform.system() == "Windows":
os.path.sep = "\\"
if platform.system().startswith("MSYS"):
# In MSYS platform, realpath has a strange behavior.
# os.path.realpath("c:\a\b\c") => \:\a\b\c