dotfiles/nvim/.config/nvim/after/ftplugin/dirvish.vim
Sanchayan Maity 679daf809a nvim: after/ftplugin/dirvish: Set bufhidden to hide
With commit 7e41cd7 entering in dirvish does not work if bufhidden is
not hide or empty. Set it to hide and using BS which is mapped to C-^
in our key mappings, we can go back to the previous buffer.
2022-04-28 15:20:44 +05:30

16 lines
521 B
VimL

setlocal bufhidden=hide
nnoremap <buffer> <silent> yy "+yy<C-^>
" Unmap all default mappings
let g:dirvish_dovish_map_keys = 0
nmap <silent> <buffer> i <Plug>(dovish_create_file)
nmap <silent> <buffer> I <Plug>(dovish_create_directory)
nmap <silent> <buffer> D <Plug>(dovish_delete)
nmap <silent> <buffer> r <Plug>(dovish_rename)
nmap <silent> <buffer> cc <Plug>(dovish_yank)
xmap <silent> <buffer> cc <Plug>(dovish_yank)
nmap <silent> <buffer> pp <Plug>(dovish_copy)
nmap <silent> <buffer> P <Plug>(dovish_move)