Fri, 16 Sep 2011 19:34:07 +0200
Ammended 'isinpath' and 'getExecutablePath' to check the current directory as well.
Utilities/__init__.py | file | annotate | diff | comparison | revisions |
--- a/Utilities/__init__.py Thu Sep 15 18:39:57 2011 +0200 +++ b/Utilities/__init__.py Fri Sep 16 19:34:07 2011 +0200 @@ -612,6 +612,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 @@ -640,6 +643,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