Last active
August 29, 2015 14:22
-
-
Save dhruvarora/94ac84316bb0f9396e0f to your computer and use it in GitHub Desktop.
Trimmed .vimrc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" This is Dhruv Arora's .vimrc file" | |
set nocompatible | |
set encoding=utf-8 | |
" ------------------------------------------------ | |
" Plugins | |
" ------------------------------------------------ | |
call plug#begin(expand('~/.vim/bundle/')) | |
" ---------------------------------------------- | |
" General Enhancements | |
" ---------------------------------------------- | |
" Syntastic plugin for syntax linting | |
Plug 'scrooloose/syntastic' | |
" Emmet" | |
Plug 'mattn/emmet-vim' | |
" Displays lines to better help separate blocks of code" | |
Plug 'Yggdroot/indentLine' | |
"JavaScript highlighting -- required for JSX" | |
Plug 'pangloss/vim-javascript' | |
"JSX Syntax Highlighting" | |
Plug 'mxw/vim-jsx' | |
call plug#end() | |
" -------------------------------------------- | |
" Syntastic settings | |
" ------------------------------------------- | |
" | |
" Python checker | |
let g:syntastic_python_checkers=['flake8'] | |
let g:syntastic_python_flake8_args='--ignore=E501' | |
" Java Checkers | |
let g:syntastic_java_checkers = ['javac', 'checkstyle'] | |
let g:syntastic_java_javac_config_file_enabled = 1 | |
" JavaScript Checkers | |
let g:syntastic_javascript_checkers = ['eslint'] | |
"let g:jsx_ext_required = 0 " Allow JSX in normal JS files | |
"let g:syntastic_javascript_checkers = ['jsxhint'] | |
"let g:syntastic_javascript_checkers = ['jshint'] | |
" Miscellaneous Syntastic settings | |
let g:syntastic_error_symbol = '✗' | |
let g:syntastic_warning_symbol = '!' | |
let g:syntastic_check_on_open = 1 | |
" ------------------------------------------------ | |
" Plugin settings | |
" ------------------------------------------------ | |
"Don't update git line diffs while typing | |
let g:gitgutter_realtime = 0 | |
let g:gitgutter_escape_grep = 1 | |
" NERDTree Root Dir " | |
let NERDTreeChDirMode=2 | |
" Make indentLine prettier | |
let g:indentLine_char = '┆' | |
" start NERDTree on start-up and focus active window | |
autocmd VimEnter * NERDTree | |
autocmd VimEnter * wincmd p | |
" ------------------------------------------------ | |
" GUI settings | |
" ------------------------------------------------ | |
" Hide MacVim toolbar and scrollbars. | |
set guioptions-=T | |
set guioptions-=r | |
set guioptions-=R | |
set guioptions-=l | |
set guioptions-=L | |
" ------------------------------------------------ | |
" Miscellaneous Vim Settings | |
" ------------------------------------------------ | |
" Assume terminal is fast for smoothness | |
set ttyfast | |
" No auditory bells | |
set visualbell | |
" Show matching bracket when a bracket is highlighted | |
set showmatch | |
" Show in the bottom line" | |
set showcmd | |
" Blink for 0.2 seconds when highlighting a bracket | |
set mat=2 | |
" Tab completion in command mode - adds highlights on second tab | |
set wildmenu | |
set wildmode=longest,full | |
" Enable syntax processing | |
syntax enable | |
" If a file is changed outside of vim, automatically reload it without asking | |
set autoread | |
" Change directory to current working file" | |
set autochdir | |
" Centralize backups, swapfiles and undo history | |
set backupdir=~/.vim/backups | |
set directory=~/.vim/swaps | |
if exists("&undodir") | |
set undodir=~/.vim/undo | |
endif | |
set ruler | |
au BufRead,BufNewFile *.hn set filetype=cpp | |
au BufRead,BufNewFile *.ejs set filetype=html | |
set splitright | |
" ------------------------------------------------ | |
" Colorscheme and Fonts | |
" ------------------------------------------------ | |
" Use Powerline font | |
set guifont=Inconsolata-dz\ for\ Powerline:h13 | |
" Use Powerline font characters for airline.vim | |
let g:airline_powerline_fonts=1 | |
" Airline theme | |
let g:airline_theme='base16' | |
" Default to 6px of space in between lines | |
set linespace=6 | |
" No eye strain | |
set background=dark | |
" Theme initialization | |
colorscheme base16-ocean | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment