aboutsummaryrefslogtreecommitdiffstats
path: root/vimrc
diff options
context:
space:
mode:
authorTeddy Wing2024-04-03 23:54:03 +0200
committerTeddy Wing2024-04-05 21:33:47 +0200
commitff8657a1a50bbbe5ef1fad71f269bca361e53f02 (patch)
tree6352c7acb6831f940619768e91a7bcea14057080 /vimrc
parentbfa73f62df16547c1c276e0521142f0711fba8ee (diff)
downloaddotvim-master.tar.bz2
vimrc: Add `[b` and `]b` buffer cycling mappingsHEADmaster
I've had these on `<leader>k` and `<leader>j` since the early days, but those mappings no longer feel logical to me. It seems that `[b` and `]b` are unbound, so I decided to bind these to buffer switching, for the rare times when I need it. Eventually I'll probably remove one or the other set depending on what I end up sticking with.
Diffstat (limited to 'vimrc')
-rw-r--r--vimrc5
1 files changed, 5 insertions, 0 deletions
diff --git a/vimrc b/vimrc
index ed9824c..4dd0015 100644
--- a/vimrc
+++ b/vimrc
@@ -506,6 +506,9 @@
" 2023.09.25:
" * Turn on 'smoothscroll'.
"
+" 2024.04.03:
+" * Add `[b` and `]b` mappings for previous and next buffer.
+"
" Pathogen
@@ -825,6 +828,8 @@ nnoremap g$ $
" Easier buffer switching
nnoremap <leader>j :bnext<cr>
nnoremap <leader>k :bprevious<cr>
+nnoremap ]b :bnext<cr>
+nnoremap [b :bprevious<cr>
" Close buffer without closing split
" http://stackoverflow.com/a/4468491