From e434d3e3913609d0b029c499ed3a38ce3edd268a Mon Sep 17 00:00:00 2001 From: Urbain Vaes Date: Thu, 9 Dec 2021 14:32:54 +0100 Subject: Improve formatting mappings --- vim/.vimrc | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/vim/.vimrc b/vim/.vimrc index 96f6fae..da2a427 100644 --- a/vim/.vimrc +++ b/vim/.vimrc @@ -11,6 +11,7 @@ let maplocalleader = "," "" Plugins {{{1 call plug#begin('~/.vim/plugged') +Plug 'andymass/vim-matchup' Plug 'PotatoesMaster/i3-vim-syntax' Plug 'SirVer/ultisnips' Plug 'airblade/vim-gitgutter' @@ -321,8 +322,9 @@ nnoremap \h :e %:p:s,.hpp$,.X123X,:s,.cpp$,.hpp,:s,.X123X$,.cpp, nnoremap Y y$ " Formatting -nnoremap fw :%s/\s\+$// -nnoremap ft :%s/^ \+//g +nnoremap fw m`:silent! keeppattern %s/\s\+$//``:update +nnoremap ft m`:silent! keeppattern %s/^ \+//g``:update +nmap ff fwft " Swap / and / cnoremap @@ -331,7 +333,7 @@ cnoremap cnoremap " Alternate file -nnoremap  +no remap  " Buffers nnoremap + :Buffers @@ -433,6 +435,8 @@ catch endtry endif +let g:matchup_override_vimtex = 1 + " Tests {{{1 let g:ripple_repls = { \ "python": { -- cgit v1.2.3