Browse Source

Make run_mypy.py slightly more cross platform.

Simon Edwards 8 years ago
parent
commit
4928c91942
1 changed files with 4 additions and 1 deletions
  1. 4 1
      run_mypy.py

+ 4 - 1
run_mypy.py

@@ -21,7 +21,10 @@ def findModules(path):
     return result
 
 def main():
-    os.putenv("MYPYPATH", r".;.\plugins;.\plugins\VersionUpgrade;..\Uranium_hint\;..\Uranium_hint\stubs\\" )
+    if sys.platform == "win32":
+        os.putenv("MYPYPATH", r".;.\plugins;.\plugins\VersionUpgrade;..\Uranium\;..\Uranium\stubs\\" )
+    else:
+        os.putenv("MYPYPATH", r".:./plugins:./plugins/VersionUpgrade:../Uranium/:../Uranium\stubs/")
 
     # Mypy really needs to be run via its Python script otherwise it can't find its data files.
     mypyExe = where("mypy.bat" if sys.platform == "win32" else "mypy")