From f3d05ab5176c03bfc5be9ef472c895734fae1a54 Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Wed, 17 Jun 2020 22:15:05 +0200 Subject: vimrc: Add count support to `[q`, `]q`, `[w`, `]w` Allow these next/previous mappings for the quickfix and location list to take counts. --- vimrc | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'vimrc') diff --git a/vimrc b/vimrc index f15ae1f..4f1b355 100644 --- a/vimrc +++ b/vimrc @@ -458,6 +458,9 @@ " 2020.02.25: " * Add `e` mapping to open the current buffer in a new tab. " +" 2020.06.17: +" * Add count support to `[q`, `]q`, `[w`, `]w`. +" " Pathogen @@ -791,12 +794,12 @@ nnoremap nnoremap e :tabedit % " Quickfix -nnoremap ]q :cnext -nnoremap [q :cprevious +nnoremap ]q :execute v:count . 'cnext' +nnoremap [q :execute v:count . 'cprevious' " Location list -nnoremap ]w :lnext -nnoremap [w :lprevious +nnoremap ]w :execute v:count . 'next' +nnoremap [w :execute v:count . 'previous' " Set scrollbind on a window nnoremap sb :setlocal scrollbind! scrollbind? -- cgit v1.2.3