Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Branch: master
225 lines (188 sloc) 4.791 kB
" security
set secure
set nomodeline
" start vim-plug
call plug#begin('~/.vim/plugged')
" plugins with no config
Plug 'alunny/pegjs-vim'
Plug 'chriskempson/base16-vim'
Plug 'dockyard/vim-easydir'
Plug 'flazz/vim-colorschemes'
Plug 'junegunn/goyo.vim'
Plug 'kshenoy/vim-signature'
Plug 'lambdatoast/elm.vim'
Plug 'lluchs/vim-wren'
Plug 'sheerun/vim-polyglot'
Plug 'sjl/vitality.vim'
Plug 'tpope/vim-commentary'
Plug 'tpope/vim-endwise'
Plug 'tpope/vim-eunuch'
Plug 'tpope/vim-fugitive'
Plug 'tpope/vim-repeat'
Plug 'vim-scripts/brainfuck-syntax'
" plugins that require other things
if has("python")
Plug 'editorconfig/editorconfig-vim'
Plug 'Valloric/MatchTagAlways'
endif
" reasonable defaults
set backspace=indent,eol,start
set autoread
set autochdir
set history=1000
set viminfo^=!
nnoremap Y y$
nnoremap 0 ^
nnoremap - $
set wildignore+=*.o,*.out,*.obj,.git,*.rbc,*.rbo,*.class,.svn,*.gem
set wildignore+=*.zip,*.tar.gz,*.tar.bz2,*.rar,*.tar.xz
set wildignore+=*/vendor/gems/*,*/vendor/cache/*,*/.bundle/*,*/.sass-cache/*
set wildignore+=*/node_modules/*
set wildignore+=*.swp,*~,._*
if has("cryptmethod")
set cryptmethod=blowfish2
endif
set ttymouse=xterm2
set mouse=
set mousehide
set nrformats-=octal
autocmd BufEnter, BufWinEnter * silent! checktime %
" indenting
set autoindent
set shiftround
" better <Esc>
set ttimeout
set ttimeoutlen=50
" search
set ignorecase
set smartcase
set incsearch
set hlsearch
set gdefault
" display stuff
set laststatus=2
set ruler
set showcmd
set number
set noerrorbells
set visualbell
set t_Co=256
if has("syntax")
syntax on
set synmaxcol=1000
endif
set nolist
set listchars=tab:\ ,eol:¬,trail:·,nbsp:·
if has("gui_running")
set title
set guifont=Fira\ Mono:h16
set antialias
set guioptions-=T
set guioptions-=r
set guioptions-=L
highlight Cursor guifg=black guibg=grey
set guicursor=n-c-v:block-Cursor-blinkon0
set guicursor+=i:ver10-Cursor
else
set notitle
endif
" wildin'
set nowildmenu
" cursor position
set nocursorline
set scrolloff=4
set sidescroll=1
set sidescrolloff=15
" better wrapping
set wrap linebreak
set showbreak=" "
" splits
set splitbelow
set splitright
" switch to a tab
set switchbuf=usetab
" english
if has("spell")
set spelllang=en_us
endif
" Git commit messages with spelling and automatic insert mode
if has("spell")
au BufNewFile,BufRead COMMIT_EDITMSG setlocal spell
endif
au BufNewFile,BufRead COMMIT_EDITMSG call feedkeys("ggi", "t")
" leader stuff
let mapleader = "\<Space>"
nnoremap <Leader>h :noh<CR>
nmap <Leader><Leader> :w<CR>:noh<CR>
" better vertical movement
noremap j gj
noremap k gk
" there is no escape
inoremap jk <esc>
" stay in visual mode when indenting
vnoremap < <gv
vnoremap > >gv
" these trip me up
nnoremap Q <nop>
nnoremap K <nop>
" buffers
set hidden
" not sure why this was happening...
nnoremap <Esc> <nop>
" file types
au BufNewFile,BufRead *.coffee set syn=coffee
au BufNewFile,BufRead vimperatorrc set syn=vim
" Indent Guides
Plug 'nathanaelkane/vim-indent-guides'
let g:indent_guides_start_level = 2
let g:indent_guides_guide_size = 1
" ctrl-p
Plug 'ctrlpvim/ctrlp.vim'
let g:ctrlp_mruf_max = 250
let g:ctrlp_use_caching = 1
let g:ctrlp_clear_cache_on_exit = 0
" NerdTree
Plug 'scrooloose/nerdtree'
map <Leader>k :NERDTreeToggle<CR>
autocmd vimenter * if !argc() | NERDTree | endif
autocmd BufEnter * if (winnr("$") == 1 && exists("b:NERDTreeType") && b:NERDTreeType == "primary")
" Syntastic
Plug 'scrooloose/syntastic'
let g:syntastic_check_on_open = 1
let g:syntastic_check_on_wq = 0
let g:syntastic_enable_signs = 1
let g:syntastic_auto_loc_list = 2
let g:syntastic_error_symbol = "X"
let g:syntastic_style_error_symbol = ">"
let g:syntastic_warning_symbol = "!"
let g:syntastic_style_warning_symbol = ">"
let g:syntastic_cpp_compiler = "g++"
let g:syntastic_cpp_check_header = 1
let g:syntastic_cpp_no_include_search = 0
" let g:syntastic_cpp_compiler_options = " -std=c++11"
let g:syntastic_javascript_checkers = ["eslint"]
let g:syntastic_coffeescript_checkers = ["coffeelint"]
let g:syntastic_ruby_checkers = ["rubocop", "mri"]
let g:syntastic_java_checkers = []
" autocomplete
Plug 'Shougo/neocomplcache'
let g:acp_enableAtStartup = 0
let g:neocomplcache_enable_at_startup = 1
let g:neocomplcache_enable_smart_case = 1
let g:neocomplcache_min_syntax_length = 2
let g:neocomplcache_enable_auto_select = 1
let g:neocomplcache_max_list = 12
let g:neocomplcache_enable_camel_case_completion = 1
let g:neocomplcache_enable_underbar_completion = 1
" finish up vim-plug
call plug#end()
" that colorscheme (has to be down here for some reason)
try
colorscheme base16-default
catch
colorscheme darkblue
endtry
" ~/.vimrc_local if you have it
if filereadable(expand("~/.vimrc_local"))
source ~/.vimrc_local
endif
Jump to Line
Something went wrong with that request. Please try again.