4 ms·
Not parent, but I use Neovim and Ranger [1] filemanager and I have a shortcut to open Ranger in a split or full window from which I can browse and open a file.
by has2k1 9y ago
Not parent, but I use Neovim and Ranger [1] filemanager and I have a shortcut to open Ranger in a split or full window from which I can browse and open a file. You can do this only because Neovim has a built-in terminal. This may end up replacing vinegar [2] as my in-VIM filemanager.
[1] https://github.com/ranger/ranger https://github.com/ranger/ranger
[2] https://github.com/tpope/vim-vinegar https://github.com/tpope/vim-vinegar
- cschneid 9y agoSo the nesting you have is Shell -> Nvim -> Ranger, so ranger is contained inside of a vim split? Mind sharing some docs on how to do that?
- Tarean 9y agoLazy version would be `:vsplit | lcd %:h | term ranger<cr>`. `vsplit` splits the window vertically. `lcd` sets the bufferlocal working directory which is a new feature in neovim. `term ranger` launches the terminal emulator. If you wanted to be fancy you could add a toggle that reuses the same ranger instance which'd add an additional ~10 loc.
- has2k1 9y agoI use a plugin ranger.vim [1]. Although it works for plain VIM, it is very clunky, since ranger is opened with a !command you get a blocking terminal. The nesting really is tmux -> Shell -> Nvim -> Ranger. https://github.com/francoiscabrol/ranger.vim https://github.com/francoiscabrol/ranger.vim