Utilities/__init__.py

changeset 1329
ac21bb9cf8b9
parent 1316
0bb67aced672
child 1348
38d4a35aa308
--- a/Utilities/__init__.py	Fri Sep 16 18:57:49 2011 +0200
+++ b/Utilities/__init__.py	Fri Sep 16 19:34:07 2011 +0200
@@ -673,6 +673,9 @@
     if os.path.isabs(file):
         return os.access(file, os.X_OK)
     
+    if os.path.exists(os.path.join(os.curdir, file)):
+        return os.access(os.path.join(os.curdir, file), os.X_OK)
+    
     path = getEnvironmentEntry('PATH')
     
     # environment variable not defined
@@ -702,6 +705,11 @@
         else:
             return ""
         
+    cur_path = os.path.join(os.curdir, file)
+    if os.path.exists(cur_path):
+        if os.access(cur_path, os.X_OK):
+            return cur_path        
+
     path = os.getenv('PATH')
     
     # environment variable not defined

eric ide

mercurial