From a567a99cca8e4e705b70afc9947e049f53d68f3c Mon Sep 17 00:00:00 2001 From: BonaBeavis Date: Fri, 29 Nov 2019 14:27:12 +0100 Subject: [PATCH] Update local current directory after opening a file This shortens the path displayed in the buffer list `:ls`. --- plugin/ranger.vim | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugin/ranger.vim b/plugin/ranger.vim index 03d5d2b..0a15afc 100644 --- a/plugin/ranger.vim +++ b/plugin/ranger.vim @@ -57,6 +57,8 @@ if has('nvim') for f in readfile(s:choice_file_path) exec self.edit_cmd . f endfor + let currentWorkingDirectory = getcwd() + :execute "lcd " . currentWorkingDirectory call delete(s:choice_file_path) endif endtry