"""""""""""""""""""""""""""""""" " General """""""""""""""""""""""""""""""" " Use pathogen https://github.com/tpope/vim-pathogen execute pathogen#infect() filetype plugin indent on " Use vim-sensible https://github.com/tpope/vim-sensible " for default settings. "set ruler " Enables the ruler "set autoindent " Add indentation of previous line "set backspace=indent,eol,start " Use Backspace more intuitively "set complete-=i " for previous and next completion "set smarttab " Tab at the beginning of line adds shiftwidth spaces "set nrformats-=octal " Don't use octal as nr format "set ttimeout " Set the timeout for mapped keybindings "set ttimeoutlen=100 " Set timeout to 100ms "set incsearch " Don't wait for , start searching right away. "nnoremap :nohlsearch=has('diff')?'diffupdate':'' " switches off search result highlighting "set laststatus=2 " Always draw the status line "set wildmenu " Show expansion candidates in status line "set scrolloff=2 " Minimum number of lines above and below cursor "set sidescrolloff=5 " Minimum number of columns to keep (only in nowrap) "set display+=lastline "set encoding=utf-8 "set listchars=tab:>\ ,trail:-,extends:>,precedes:<,nbsp:+ "set formatoptions+=j " Delete comment characters when joining lines. "setglobal tags-=./tags tags-=./tags; tags^=./tags; "set shell=/bin/bash "set autoread " When a change is detected, auto reload the file "set history=1000 "set tabpagemax=50 "set viminfo^=! "set sessionoptions-=options "set t_Co=16 "runtime! macros/matchit.vim "inoremap u set backupdir=$HOME/.vim/backup_files// set directory=$HOME/.vim/swap_files// set undodir=$HOME/.vim/undo_files// " Use Syntastic https://github.com/vim-syntastic/syntastic " for syntax checks. let g:syntastic_javascript_checkers = ['standard'] " JavaScript " Check syntax on write and fix formatting. autocmd bufwritepost *.js silent !standard --fix % " use , as map leader. let mapleader="," let g:mapleader="," " quick save with ,w nmap w :w! set cmdheight=2 set hid set whichwrap+=<,>,h,l """"""""""" " Searching """"""""""" set hlsearch " ignore case when searching. set smartcase set lazyredraw set magic set showmatch set mat=2 set noerrorbells set novisualbell set t_vb= set tm=500 try colorscheme desert catch endtry set background=dark set ffs=unix,dos,mac set nobackup set nowb set noswapfile set expandtab set lbr set tw=500 set smartindent set wrap " Keybindings map l :bnext map h :bprev map tn :tabnew map to :tabonly map tc :tabclose map tm :tabmove map t :tabnext set statusline=\ %F%m%r%h\ %w\ \ CWD:\ %r%{getcwd()}%h\ \ \ Line:\ %l\ \ Column:\ %c map 0 ^ set gdefault set number set background=dark set ffs=unix,dos,mac " Indentation set shiftwidth=2 set softtabstop=2