From a000e9d1a0c33a039a1947a6120a57bb56c996f5 Mon Sep 17 00:00:00 2001 From: Mikko Lehto Date: Tue, 29 Aug 2017 19:37:47 +0300 Subject: [PATCH] vimrc: strip trailing whitespace --- vim/vimrc | 1 + 1 file changed, 1 insertion(+) diff --git a/vim/vimrc b/vim/vimrc index 7a67d6c..5275cee 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -10,6 +10,7 @@ imap :pyf /usr/local/llvm39/share/clang/clang-format.py " http://www.alexeyshmalko.com/2014/using-vim-as-c-cpp-ide/ " ! mark prevents Vim from jumping to location of first error found nnoremap :make! +nnoremap :let _s=@/ :%s/\s\+$//e :let @/=_s :nohl :unlet _s set makeprg=gmake if has('gui_running')