aboutsummaryrefslogtreecommitdiff
path: root/vim/vimrc
diff options
context:
space:
mode:
Diffstat (limited to 'vim/vimrc')
-rw-r--r--vim/vimrc9
1 files changed, 6 insertions, 3 deletions
diff --git a/vim/vimrc b/vim/vimrc
index d017dfe9..523bace5 100644
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -331,12 +331,15 @@ if exists(':xnoremap')
endif
" \o opens a line below in paste mode
-nmap <Bslash>o <Plug>(PasteOpenBelow)
+nmap <Bslash>o <Plug>(PasteHook)o
" \O opens a line above in paste mode
-nmap <Bslash>O <Plug>(PasteOpenAbove)
+nmap <Bslash>O <Plug>(PasteHook)O
-" \p toggles paste mode
+" \p toggles paste mode, or sets a hook if plugin available
nnoremap <Bslash>p :<C-U>set paste! paste?<CR>
+if &loadplugins
+ nmap <Bslash>p <Plug>(PasteHook)
+endif
" \q formats the current paragraph
nnoremap <Bslash>q gqap