aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-07-01 23:15:17 +1200
committerTom Ryder <tom@sanctum.geek.nz>2018-07-01 23:15:17 +1200
commit320faa7654ab04216e61c6c0c419e2042bc80853 (patch)
tree99489ad27e3b75dcb493ea5b80827f27c11b0a5f
parentRemove conditional around \d,\D maps (diff)
downloaddotfiles-320faa7654ab04216e61c6c0c419e2042bc80853.tar.gz
dotfiles-320faa7654ab04216e61c6c0c419e2042bc80853.zip
Reorder mappings
-rw-r--r--vim/vimrc32
1 files changed, 16 insertions, 16 deletions
diff --git a/vim/vimrc b/vim/vimrc
index b4769216..2ba4fdff 100644
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -164,6 +164,19 @@ if has('windows')
endif
endif
+" Remap normal J to stay in place while joining lines
+if &loadplugins
+ nmap J <Plug>FixedJoin
+endif
+
+" Remap normal Y to yank to end of line (consistent with C, D)
+nnoremap Y y$
+
+" ZA unconditionally writes all buffers
+nnoremap ZA :<C-U>wall!<CR>
+" ZW unconditionally writes current buffer
+nnoremap ZW :<C-U>write!<CR>
+
" Remap normal/visual <Space> to scroll down a page
nnoremap <Space> <C-F>
if v:version >= 700
@@ -176,15 +189,15 @@ if v:version >= 700
xnoremap <silent> & :&&<CR>
endif
-" Stack insert Ctrl-C to undo the escaped insert operation
-inoremap <C-C> <C-C>u
-
" Stack normal/visual Ctrl-L to clear search highlight before redraw
nnoremap <silent> <C-L> :<C-U>nohlsearch<CR><C-L>
if v:version >= 700
xnoremap <silent> <C-L> :<C-U>nohlsearch<CR>gv<C-L>
endif
+" Stack insert Ctrl-C to undo the escaped insert operation
+inoremap <C-C> <C-C>u
+
" Cycle through argument list
nnoremap [a :<C-U>previous<CR>
nnoremap ]a :<C-U>next<CR>
@@ -205,19 +218,6 @@ nnoremap ]t :<C-U>tabnext<CR>
nmap [<Space> <Plug>PutBlankLinesAbove
nmap ]<Space> <Plug>PutBlankLinesBelow
-" Remap normal J to stay in place while joining lines
-if &loadplugins
- nmap J <Plug>FixedJoin
-endif
-
-" Remap normal Y to yank to end of line (consistent with C, D)
-nnoremap Y y$
-
-" ZA unconditionally writes all buffers
-nnoremap ZA :<C-U>wall!<CR>
-" ZW unconditionally writes current buffer
-nnoremap ZW :<C-U>write!<CR>
-
" Normal mode leader mappings below; use <Bslash> rather than <Leader> on the
" non-plugin maps so that they work on vim-tiny