mirror of
https://github.com/tpope/vim-repeat.git
synced 2026-09-10 07:16:26 -04:00
preserve Ctrl-R map
works fine if <c-r> is not an <expr> map
This commit is contained in:
parent
5eba0f19c8
commit
f13237c4c4
|
|
@ -108,7 +108,9 @@ nnoremap <silent> u :<C-U>call repeat#wrap('u',v:count)<CR>
|
|||
if maparg('U','n') ==# ''
|
||||
nnoremap <silent> U :<C-U>call repeat#wrap('U',v:count)<CR>
|
||||
endif
|
||||
nnoremap <silent> <C-R> :<C-U>call repeat#wrap("\<Lt>C-R>",v:count)<CR>
|
||||
let ctrlR = (maparg('<C-R>','n') == "" ? '<C-R>' :maparg('<C-R>', 'n'))
|
||||
substitute(ctrlR,'<','\<Lt>','g')
|
||||
execute 'nnoremap <silent> <C-R> :<C-U>call repeat#wrap("'. ctrlR .'",v:count)<CR>'
|
||||
|
||||
augroup repeatPlugin
|
||||
autocmd!
|
||||
|
|
|
|||
Loading…
Reference in a new issue