X-Git-Url: https://ruderich.org/simon/gitweb/?a=blobdiff_plain;f=vimrc;h=35edbdfd31b057f2f582cfe370fccd0c9d979b5c;hb=6809eb2f93254f331798c1474e15f280dd476414;hp=97d0c371cfdce3393c500537e02bc7e53cf31200;hpb=2cc93b7ada0b925d1ccecfa19a8b3f04cba13f2b;p=config%2Fdotfiles.git diff --git a/vimrc b/vimrc index 97d0c37..35edbdf 100644 --- a/vimrc +++ b/vimrc @@ -34,6 +34,8 @@ set runtimepath^=~/.vim,~/.vim/runtime " Don't store swap files in the same directory as the edited file. set directory-=. +" But store them in ~/.tmp if available. +set directory^=~/.tmp " Disable modelines as they may cause security problems. Instead use " securemodelines (Vim script #1876). @@ -221,15 +223,14 @@ cmap cnoremap cnoremap +" Write before suspending, thanks to deryni in #vim on Freenode (2011-05-09 +" 20:02 CEST). To suspend without saving either unmap it or use :stop. +nnoremap :update:stop + " Use to move down a page and - to move up one like in mutt. nnoremap nnoremap - -" Behave like 'scrolloff' but only while searching. Thanks to "Benjamin R. -" Haskell" from the Vim mailing list (2010-10-26). -nnoremap n nzv3j3k -nnoremap N Nzv3k3j - " Go to next and previous buffer. Thanks to elik in #vim on Freenode " (2010-05-16 18:38 CEST) for this idea. nnoremap gb :bnext