New answers tagged

0

Another option is modifying the netrw.vim script found in /usr/share/vim/vim<your version here>/autoload/ as follows: nnoremap <buffer> <silent> P : call NetrwGetPath() function! NetrwGetPath() let dirname = s:NetrwTreeDir(0) let filename = s:NetrwGetWord() ...


0

Riffing off of this answer, I added these lines to my .vimrc to enable mouse support only when starting, entering, or leaving netrw buffer. function! NetrwMouseOn() set mouse=n endfunction function! NetrwMouseOff() set mouse= endfunction au FileType netrw :call NetrwMouseOn() au FileType netrw au BufEnter <buffer> :call NetrwMouseOn() au ...


3

netrw is a plugin, just one that is distributed with vim itself. For me, :Explore and friends are defined in /usr/local/share/vim/vim82/plugin/netrwPlugin.vim. From the load-plugins section of :h initialization, step 4: Load the plugin scripts. This does the same as the command: :runtime! plugin/**/*.vim The result is that all directories in the '...


0

Tried all kind of solutions from here and some other places, none worked as expected, respectively I didn't like the implementation much (e.g. the one using augroup netrw_buf_hidden_fix), so I ended up with this for closing netrw using Esc or q autocmd FileType netrw nnoremap <buffer><silent> <Esc> :call <SID>CloseNetrw()<CR> ...


Top 50 recent answers are included