" Install vim-plug if it is not already installed, for " Portability's sake if empty(glob('~/.vim/autoload/plug.vim')) silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs \ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim autocmd VimEnter * PlugInstall --sync | source $MYVIMRC endif " Plugins will be downloaded under the specified directory. call plug#begin('~/.vim/plugged') " Declare the list of plugins. Plug 'itchyny/lightline.vim' " Plug 'preservim/nerdtree' Plug 'tpope/vim-vinegar' Plug 'tpope/vim-surround' Plug 'tpope/vim-fugitive' Plug 'terryma/vim-multiple-cursors' Plug 'ap/vim-css-color' Plug 'vimwiki/vimwiki' " List ends here. Plugins become visible to Vim after this call. call plug#end() " Personal preference stuff set number set tabstop=4 set smartcase " Syntax and some plugins :filetype plugin on :syntax on " Use mouse set mouse=a set ttymouse=sgr " lightline is installed so this is not necessary set noshowmode set laststatus=2 if !has('gui_running') set t_Co=256 endif " NERDTree " map :NERDTreeToggle " Start nerdtree when no file is specified " autocmd StdinReadPre * let s:std_in=1 " autocmd VimEnter * if argc() == 0 && !exists("s:std_in") | NERDTree | endif " autocmd VimEnter * if argc() == 1 && isdirectory(argv()[0]) && !exists("s:std_in") | exe 'NERDTree' argv()[0] | wincmd p | ene | exe 'cd '.argv()[0] | endif