Last active
April 13, 2019 12:54
-
-
Save WMahoney09/2d3c891a3cf246d42dbce1d03d787860 to your computer and use it in GitHub Desktop.
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
# .vimrc og | |
autocmd vimenter * NERDTree | |
nnoremap <C-e> :NERDTreeToggle<CR> | |
syntax on | |
set ru | |
set number | |
set shiftwidth=2 | |
let g:ctrlp_map='<c-p>' | |
let g:ctrlp_cmd='CtrlP' | |
let g:ctrlp_working_path_mode='c' | |
call plug#begin('~/.vim/plugged') | |
Plug 'scrooloose/nerdTree' | |
Plug 'kien/ctrlp.vim' | |
call plug#end() | |
# vimrc 2 | |
set t_Co=256 | |
autocmd vimenter * NERDTree | |
nnoremap <C-e> :NERDTreeToggle<CR> | |
syntax enable | |
set bg=dark | |
let g:solarized_termcolors=256 | |
let g:airline_powerline_fonts=1 | |
"colorscheme solarized | |
filetype plugin on | |
set ru | |
set number | |
set shiftwidth=2 | |
set laststatus=2 | |
let g:ctrlp_map='<c-p>' | |
let g:ctrlp_cmd='CtrlP' | |
let g:ctrlp_working_path_mode='c' | |
let g:ackprg='ag --nogroup --nocolor --column' | |
call plug#begin('~/.vim/plugged') | |
Plug 'milszs/ack.vim' | |
Plug 'scrooloose/nerdTree' | |
Plug 'ddollar/nerdcommenter' | |
Plug 'kien/ctrlp.vim' | |
Plug 'ntpeters/vim-better-whitespace' | |
Plug 'airblade/vim-gitgutter' | |
Plug 'tpope/vim-fugitive' | |
Plug 'vim-airline/vim-airline' | |
call plug#end() | |
# vimrc 3 | |
" Boiler | |
set mouse=n | |
set nocompatible " be iMproved, required | |
syntax enable | |
set nu | |
set ru | |
filetype off " required | |
set expandtab | |
set smarttab | |
set tabstop=8 | |
set shiftwidth=4 | |
set softtabstop=0 | |
set laststatus=2 | |
set autoindent | |
set hlsearch | |
" Fold config | |
set foldmarker=\/\*\*,\*\/ | |
set foldmethod=marker | |
" Plugins | |
" set the runtime path to include Vundle and initialize | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() | |
" alternatively, pass a path where Vundle should install plugins | |
"call vundle#begin('~/some/path/here') | |
" let Vundle manage Vundle, required | |
Plugin 'VundleVim/Vundle.vim' | |
Plugin 'alvan/vim-closetag' | |
Plugin 'vim-airline/vim-airline' | |
Plugin 'vim-airline/vim-airline-themes' | |
Plugin 'scrooloose/nerdTree' | |
Plugin 'kien/ctrlp.vim' | |
Plugin 'tpope/vim-fugitive' | |
Plugin 'airblade/vim-gitgutter' | |
Plugin 'ddollar/nerdcommenter' | |
Plugin 'ntpeters/vim-better-whitespace' | |
Plugin 'vim-syntastic/syntastic' | |
Plugin 'mileszs/ack.vim' | |
Plugin 'gregsexton/gitv' | |
Plugin 'jelera/vim-javascript-syntax' | |
Plugin 'Raimondi/delimitMate' | |
Plugin 'nathanaelkane/vim-indent-guides' | |
Plugin 'terryma/vim-multiple-cursors' | |
" All of your Plugins must be added before the following line | |
call vundle#end() " required | |
filetype plugin indent on " required | |
" Halp | |
" To ignore plugin indent changes, instead use: | |
"filetype plugin on | |
" | |
" Brief help | |
" :PluginList - lists configured plugins | |
" :PluginInstall - installs plugins; append `!` to update or just :PluginUpdate | |
" :PluginSearch foo - searches for foo; append `!` to refresh local cache | |
" :PluginClean - confirms removal of unused plugins; append `!` to auto-approve removal | |
" | |
" see :h vundle for more details or wiki for FAQ | |
" Put your non-Plugin stuff after this line | |
" Linter | |
set statusline+=%#warningmsg# | |
set statusline+=%{SyntasticStatuslineFlag()} | |
set statusline+=%* | |
let g:syntastic_javascript_checkers=['eslint'] | |
let g:syntastic_javascript_eslint_exe='$(npm bin)/eslint' | |
let g:syntastic_always_populate_loc_list=1 | |
let g:syntastic_loc_list_height=5 | |
let g:syntastic_auto_loc_list=0 | |
let g:syntastic_check_on_open=1 | |
let g:syntastic_check_on_wq=0 | |
hi SyntasticErrorSign ctermfg=yellow ctermbg=red | |
"let g:syntastic_debug=3 | |
" Vim Airline | |
let g:airline_theme='bubblegum' | |
let g:airline#extensions#branch#displayed_head_limit=20 | |
let g:airline#extensions#default#layout = [ | |
\['a', 'c'], | |
\['z', 'error', 'warning'] | |
\] | |
"let g:airline#extensions#default#section_truncate_width = { | |
" \ 'b': 4, | |
" \ 'x': 4, | |
" \ 'y': 4, | |
" \ 'z': 4 | |
" \ } | |
" Colors | |
" default schemes can be found in `/usr/share/vim/vim80/colors` | |
set t_Co=256 | |
colorscheme desierto | |
" CtrlP | |
let g:ctrlp_custom_ignore='node_modules\|git' | |
set wildignore+=**/node_modules/** | |
" Nerd Commenter | |
let g:NERDSpaceDelims = 1 | |
" Silver Searcher | |
if executable('ag') | |
" Use ag over grep | |
let g:ackprg='ag --vimgrep' | |
" Use ag in CtrlP for listing files. Lightning fast and respects .gitignore | |
let g:ctrlp_user_command = 'ag %s -l --nocolor -g ""' | |
" ag is fast enough that CtrlP doesn't need to cache | |
let g:ctrlp_use_caching = 0 | |
endif | |
" Indent Guides | |
let g:indent_guides_enable_on_vim_startup=1 | |
set ts=4 sw=4 et | |
let g:indent_guides_start_level=2 | |
let g:indent_guides_guide_size=1 | |
" HTML Close Tag settings | |
let g:closetag_filenames='*.html,*.xml,*.jsx' | |
let g:closetag_xhtml_filenames='*.jsx' | |
let g:closetag_emptyTags_caseSensitive=1 | |
let g:closetag_shortcut='>' | |
" Key Mappings | |
nnoremap <C-E> :NERDTreeToggle<CR> | |
nnoremap <C-F> :NERDTreeFind<CR> | |
nnoremap <C-O> :diffget<CR> ]c | |
nnoremap <C-I> :diffput<CR> ]c | |
nnoremap <C-X> :Gstatus<CR> | |
nnoremap K :Ack! "\b<C-R><C-W>\b"<CR>:cw<CR> | |
nnoremap F :Ack! "\b<C-R><C-W>\b" <C-R>%<CR>:cw<CR> | |
cnoreabbrev ag Ack! | |
nnoremap <C-L> :Errors<CR><C-W>j | |
imap <C-c> <CR><Esc>O |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment