]> git.zndr.dk Git - dotfiles.git/commitdiff
Simple ~/.vimrc
authorJannik Zander <jannikz@gmail.com>
Sat, 21 May 2016 06:42:20 +0000 (08:42 +0200)
committerJannik Zander <jannikz@gmail.com>
Sat, 21 May 2016 06:43:02 +0000 (08:43 +0200)
.config/vim/vimrc
.vimrc

index 8251f49772fc6d007963c3b31f5beb8f42d3bdeb..3164868a15a853eb3c44b9cc313da85eafe0f809 100644 (file)
@@ -1,4 +1,18 @@
 set nocompatible
+set directory=$HOME/.cache/vim/swap
+set backupdir=$HOME/.cache/vim/backup
+set undodir=$HOME/.cache/vim/undo
+set viminfo+=n$HOME/.local/share/vim/viminfo
+"set rtp=~/$HOME/.config/vim,~/$HOME/.config/vim/after,$VIM,$VIMRUNTIME
+
+if empty(glob('$HOME/.config/vim/autoload/plug.vim'))
+  silent !mkdir -p $HOME/.cache/vim/swap > /dev/null 2>&1
+  silent !mkdir -p $HOME/.cache/vim/backup > /dev/null 2>&1
+  silent !mkdir -p $HOME/.cache/vim/undo > /dev/null 2>&1
+  silent !curl -fLo $HOME/.config/vim/autoload/plug.vim --create-dirs
+    \ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
+  autocmd VimEnter * PlugInstall | source $MYVIMRC
+endif
 
 if filereadable(expand('$HOME/.config/vim/autoload/plug.vim'))
 source $HOME/.config/vim/autoload/plug.vim
diff --git a/.vimrc b/.vimrc
index 9992293c420cd1676bdf0b1dea51362f31304a6f..e09ede9cf755ac69670b2cb5206f96938fcdb1ea 100644 (file)
--- a/.vimrc
+++ b/.vimrc
@@ -1,19 +1,3 @@
 " ~/.vimrc
 
-set nocompatible
-set directory=$HOME/.cache/vim/swap
-set backupdir=$HOME/.cache/vim/backup
-set undodir=$HOME/.cache/vim/undo
-set viminfo+=n$HOME/.local/share/vim/viminfo
-"set rtp=~/$HOME/.config/vim,~/$HOME/.config/vim/after,$VIM,$VIMRUNTIME
-
-if empty(glob('$HOME/.config/vim/autoload/plug.vim'))
-  silent !mkdir -p $HOME/.cache/vim/swap > /dev/null 2>&1
-  silent !mkdir -p $HOME/.cache/vim/backup > /dev/null 2>&1
-  silent !mkdir -p $HOME/.cache/vim/undo > /dev/null 2>&1
-  silent !curl -fLo $HOME/.config/vim/autoload/plug.vim --create-dirs
-    \ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
-  autocmd VimEnter * PlugInstall | source $MYVIMRC
-endif
-
 source $HOME/.config/vim/vimrc