aboutsummaryrefslogtreecommitdiff
path: root/vim
diff options
context:
space:
mode:
Diffstat (limited to 'vim')
-rw-r--r--vim/vimrc13
1 files changed, 8 insertions, 5 deletions
diff --git a/vim/vimrc b/vim/vimrc
index 6aa1838b..817b6938 100644
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -1554,9 +1554,10 @@ nnoremap <Leader>+
"" Leader,_ uses last changed or yanked text as an object
onoremap <Leader>_
\ :<C-U>execute 'normal! `[v`]'<CR>
-"" Leader,% uses entire buffer as an object
+"" Leader,% or Leader,5 uses entire buffer as an object
onoremap <Leader>%
\ :<C-U>execute 'normal! 1GVG'<CR>
+omap <Leader>5 <Leader>%
" This group defines some useful motions, including navigating by indent
" block using a custom plugin:
@@ -1601,17 +1602,19 @@ nnoremap <Leader>?
"" Leader,. runs the configured make program into the location list
nnoremap <Leader>.
\ :<C-U>lmake!<CR>
-"" Leader,! repeats the last command, adding a bang
-nnoremap <Leader>!
- \ :<Up><Home><S-Right>!<CR>
"" Leader,q formats the current paragraph
nnoremap <Leader>q gqap
"" Leader,r acts as a replacement operator
nmap <Leader>r <Plug>(ReplaceOperator)
xmap <Leader>r <Plug>(ReplaceOperator)
-"" Leader,* escapes regex metacharacters
+"" Leader,!/1 repeats the last command, adding a bang
+nnoremap <Leader>!
+ \ :<Up><Home><S-Right>!<CR>
+nmap <Leader>1 <Leader>!
nmap <Leader>* <Plug>(RegexEscape)
+nmap <Leader>8 <Leader>*
xmap <Leader>* <Plug>(RegexEscape)
+xmap <Leader>8 <Leader>*
" And last, but definitely not least, I'm required by Vim fanatic law to
" include a mapping that reloads my whole configuration. This uses the