fixed perl bug and improved path tab-complete
--HG-- branch : pmacs2
This commit is contained in:
parent
3e23f41203
commit
6fccb54b16
|
@ -56,6 +56,7 @@ class FileCompleter(Completer):
|
|||
candidates = [util.expand_tilde(user) for user in users if user.startswith(s)]
|
||||
else:
|
||||
candidates = glob.glob(s + '*')
|
||||
candidates = [util.normal_path(p) for p in candidates]
|
||||
|
||||
# ignore some suffixes by default, unless the only possible completions
|
||||
# ALL have ignored-suffixes, in which case just return them all.
|
||||
|
|
|
@ -34,7 +34,8 @@ def current_working_dir(window):
|
|||
|
||||
def path_dirname(window):
|
||||
if hasattr(window.buffer, 'path'):
|
||||
return util.normal_path(window.buffer.path) + '/'
|
||||
path = os.path.dirname(window.buffer.path)
|
||||
return util.normal_path(path) + '/'
|
||||
else:
|
||||
return current_working_dir(window)
|
||||
|
||||
|
|
Loading…
Reference in New Issue