" {{ ansible_managed }} set nocompatible " be iMproved filetype off " required! let mapleader="," " change the leader to be a comma vs slash let iCanHazVundle=1 let vundle_readme=expand('~/.vim/bundle/Vundle.vim/README.md') if !filereadable(vundle_readme) echo "Installing Vundle.." echo "" silent !mkdir -p ~/.vim/bundle silent !git clone https://github.com/gmarik/Vundle.vim.git ~/.vim/bundle/Vundle.vim let iCanHazVundle=0 endif set rtp+=~/.vim/bundle/Vundle.vim call vundle#begin() Plugin 'tpope/vim-rails' Plugin 'scrooloose/nerdtree' Plugin 'slim-template/vim-slim' Plugin 'scrooloose/syntastic' " not compatible with vim on servers " Bundle 'Valloric/YouCompleteMe' Plugin 'airblade/vim-gitgutter' Plugin 'bronson/vim-trailing-whitespace' call vundle#end() if iCanHazVundle == 0 echo "Installing Bundles, please ignore key map error messages" echo "" :BundleInstall endif syntax on filetype plugin indent on set backupdir=~/.vim.backupdir set backup " keep a backup file set autoindent " copy indent from current line set undofile " persistent undo set undoreload=10000 set undodir=~/.vimundo " Softtabs, 2 spaces set tabstop=2 set shiftwidth=2 set expandtab command! -bar SudoWrite : \ setlocal nomodified | \ exe (has('gui_running') ? '' : 'silent') 'write !sudo tee % >/dev/null' | \ let &modified = v:shell_error cmap w!! SudoWrite " Local config if filereadable($HOME . "/.vimrc.local") source ~/.vimrc.local endif