diff options
author | hut <hut@lavabit.com> | 2009-12-15 23:44:49 +0100 |
---|---|---|
committer | hut <hut@lavabit.com> | 2009-12-15 23:44:49 +0100 |
commit | e48e3c5c5046bf992a563d112629f10a3adc8168 (patch) | |
tree | eb1a41180d2918dbe78da52b3730fa53fc6bf6a2 /ranger/container/environment.py | |
parent | 7ec262f86c81c4df4360643b05dfb788d294a8ae (diff) | |
download | ranger-e48e3c5c5046bf992a563d112629f10a3adc8168.tar.gz |
fixed CD command / tab completion
Diffstat (limited to 'ranger/container/environment.py')
-rw-r--r-- | ranger/container/environment.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ranger/container/environment.py b/ranger/container/environment.py index a6d291cf..11c0082b 100644 --- a/ranger/container/environment.py +++ b/ranger/container/environment.py @@ -1,4 +1,4 @@ -from os.path import abspath, normpath, join, expanduser +from os.path import abspath, normpath, join, expanduser, isdir from ranger.fsobject.directory import Directory, NoDirectoryGiven from ranger.container import KeyBuffer, History from ranger.shared import SettingsAware @@ -91,6 +91,9 @@ level <0 => parent directories""" # get the absolute path path = normpath(join(self.path, expanduser(path))) + if not isdir(path): + return + try: new_pwd = self.get_directory(path) except NoDirectoryGiven: |