diff --git a/rshell/main.py b/rshell/main.py index 40071f5..3cd33ed 100755 --- a/rshell/main.py +++ b/rshell/main.py @@ -850,7 +850,13 @@ def add_suffix_if_dir(filename): # This can happen when a symlink points to a non-existant file. pass return filename - if not os.path.isdir(dirname): + def isdir(path): + try: + mode = os.stat(path)[0] + return mode & 0o040000 + except OSError: + return False + if not isdir(dirname): return [] matches = [add_suffix_if_dir(result_prefix + filename) for filename in os.listdir(dirname) if filename.startswith(match_prefix)] diff --git a/rshell/version.py b/rshell/version.py index d9edf17..9ae29b1 100644 --- a/rshell/version.py +++ b/rshell/version.py @@ -1 +1 @@ -__version__ = '0.0.33' +__version__ = '0.0.34' diff --git a/setup.py b/setup.py index 1652e55..be4be84 100644 --- a/setup.py +++ b/setup.py @@ -50,6 +50,6 @@ }, extras_require={ ':sys_platform == "win32"': [ - 'pyreadline'] + 'pyreadline3'] } )