" github.com/samnang/dotfiles/blob/master/vimrc " http://nvie.com/posts/how-i-boosted-my-vim/ " http://learnvimscriptthehardway.stevelosh.com/chapters/52.html " May install in the future: " Git wrapper, similar to magit: 'https://github.com/tpope/vim-fugitive' " https://github.com/tony/vim-config let mapleader="," " set leader early as otherwise it wouldn't work " ----- NeoBundle ----- " Note: Skip initialization for vim-tiny or vim-small. if 0 | endif let first_run=0 if !filereadable(expand('~/.vim/bundle/neobundle.vim/README.md')) let first_run=1 silent !git clone https://github.com/Shougo/neobundle.vim ~/.vim/bundle/neobundle.vim endif if has('vim_starting') if &compatible set nocompatible " Be iMproved endif set runtimepath+=~/.vim/bundle/neobundle.vim/ endif call neobundle#begin(expand('~/.vim/bundle/')) NeoBundleFetch 'Shougo/neobundle.vim' NeoBundle 'Shougo/vimproc.vim', { \ 'build' : { \ 'windows' : 'tools\\update-dll-mingw', \ 'cygwin' : 'make -f make_cygwin.mak', \ 'mac' : 'make -f make_mac.mak', \ 'linux' : 'make', \ 'unix' : 'gmake', \ }, \ } NeoBundle 'Lokaltog/vim-distinguished' NeoBundle 'xolox/vim-reload' NeoBundle 'xolox/vim-misc' NeoBundle 'Shougo/unite.vim' NeoBundle 'bling/vim-airline' NeoBundle 'scrooloose/syntastic' NeoBundle 'scrooloose/nerdcommenter' NeoBundle 'tpope/vim-surround' NeoBundle 'davidhalter/jedi-vim' NeoBundle 'wting/rust.vim' NeoBundle 'ledger/vim-ledger' NeoBundle 'junegunn/vim-easy-align' "NeoBundle 'msanders/snipmate.vim' "NeoBundle 'godlygeek/tabular' "NeoBundle 'plasticboy/vim-markdown' " Disable plugins for very large files NeoBundleLazy 'vim-scripts/LargeFile' call neobundle#end() filetype plugin indent on if first_run NeoBundleInstall else NeoBundleCheck endif " ----- general settings ----- set encoding=utf-8 set ff=unix set number set clipboard=unnamedplus set showmatch " show matching brackets set incsearch " Find as you type search set hlsearch " Highlight search terms set ignorecase " Case-insensitive searching. set smartcase " But case-sensitive if expression contains a capital letter. set history=1000 " remember more commands and search history set undolevels=1000 " use many levels of undo set nobackup set noswapfile set tabstop=4 set shiftwidth=4 set textwidth=80 set cc=81 set list set listchars=tab:>-,trail:~ map 1 :diffget 2 :diffupdate map 2 :diffget 3 :diffupdate map 3 :diffget 4 :diffupdate autocmd InsertEnter * :let @/="" autocmd InsertLeave * :let @/="" "set expandtab map Q @ map :tabprevious map m :tabnext syntax enable set background=dark colorscheme distinguished " remove trailing whitespaces on save autocmd BufWritePre * :%s/\s\+$//e " Markdown autocmd BufRead,BufNew *.md set filetype=markdown " airline set laststatus=2 let g:airline_theme = 'powerlineish' "let g:airline#extensions#tabline#enabled = 1 " make tabs look crazy " only enable trailing whitespace checking let g:airline#extensions#whitespace#checks = [ 'trailing' ] let g:airline#extensions#syntastic#enabled = 0 " Unite nnoremap :Unite file_rec/async " Start interactive EasyAlign in visual mode (e.g. vip) vmap (EasyAlign) " Start interactive EasyAlign for a motion/text object (e.g. gaip) nmap ga (EasyAlign)