]> git.zndr.dk Git - dotfiles.git/commitdiff
Move vim config to .config/vim
authorJannik Zander <jannikz@gmail.com>
Fri, 20 May 2016 22:13:47 +0000 (00:13 +0200)
committerJannik Zander <jannikz@gmail.com>
Fri, 20 May 2016 22:13:47 +0000 (00:13 +0200)
.vimrc

diff --git a/.vimrc b/.vimrc
index a50ab71c40fdcc379de9ac180d59643c5eab6748..359cf9f1020a7674899116862a21f926e7a9a524 100644 (file)
--- a/.vimrc
+++ b/.vimrc
@@ -1,13 +1,16 @@
 " ~/.vimrc
 
 set nocompatible
-if empty(glob('$HOME/.vim/autoload/plug.vim'))
-  silent !curl -fLo $HOME/.vim/autoload/plug.vim --create-dirs
+if empty(glob('$HOME/.config/vim/autoload/plug.vim'))
+  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
 
-call plug#begin('$HOME/.vim/plugged')
+
+if filereadable(expand('$HOME/.config/vim/autoload/plug.vim'))
+source $HOME/.config/vim/autoload/plug.vim
+call plug#begin('$HOME/.config/vim/plugged')
 
 "Plug 'tpope/vim-sensible'
 "Plug 'tpope/vim-ragtag'
@@ -29,7 +32,7 @@ Plug 'scrooloose/nerdtree'
 Plug 'vim-scripts/a.vim'
 
 call plug#end()
-
+endif
 " Section: Options {{{1
 " ---------------------
 
@@ -85,7 +88,7 @@ set number
 set undodir=~/.cache/vim/undo " vim will not create this directory.
 set directory=~/.cache/vim/swap " vim will not create this directory.
 set backupdir=~/.cache/vim/backup " vim will not create this directory.
-set viminfo+=n~/.cache/vim/viminfo
+set viminfo+=n~/.local/share/vim/viminfo
 
 " Plugin Settings {{{2
 
@@ -208,6 +211,6 @@ if (&t_Co > 2 || has("gui_running")) && has("syntax")
  endif
 " }}}1
 
-if filereadable(expand("$HOME/.vimrc_local"))
-  source $HOME/.vimrc_local
+if filereadable(expand('$HOME/.config/vim/vimrc_local'))
+  source $HOME/.config/vim/vimrc_local
 endif