Skip to content

Instantly share code, notes, and snippets.

@erich
Last active August 6, 2017 19:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save erich/1e5d6bc9d98365f7ddb2 to your computer and use it in GitHub Desktop.
Save erich/1e5d6bc9d98365f7ddb2 to your computer and use it in GitHub Desktop.
my vimrc
"from gary bernhardt's dotfiles [57/888]
set nocompatible
" allow unsaved background buffers and remember marks/undo for them
set hidden
" remember more commands and search history
set history=10000
set expandtab
set tabstop=4
set shiftwidth=4
set softtabstop=4
set autoindent
set laststatus=2
set showmatch
set incsearch
set hlsearch
" make searches case-sensitive only if they contain upper-case characters
set ignorecase smartcase
" highlight current line
set cursorline
set cmdheight=1
set switchbuf=useopen
set numberwidth=5
set showtabline=2
set winwidth=79
set t_ti= t_te=
" keep more context when scrolling off the end of a buffer
set scrolloff=3
" Store temporary files in a central spot
set backup
set backupdir=~/.vim-tmp,~/.tmp,~/tmp,/var/tmp,/tmp
set directory=~/.vim-tmp,~/.tmp,~/tmp,/var/tmp,/tmp
" allow backspacing over everything in insert mode
set backspace=indent,eol,start
" display incomplete commands
set showcmd
filetype off " required!
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" let Vundle manage Vundle
" required!
Plugin 'gmarik/vundle'
" My Plugins here:
"
" original repos on github
Plugin 'tpope/vim-fugitive'
Plugin 'Lokaltog/vim-easymotion'
Plugin 'jeetsukumaran/vim-buffergator.git'
Plugin 'rstacruz/sparkup', {'rtp': 'vim/'}
Plugin 'tpope/vim-rails.git' [6/888]
Plugin 'kien/ctrlp.vim.git'
Plugin 'altercation/vim-colors-solarized'
Plugin 'jgdavey/vim-turbux.git'
Plugin 'benmills/vimux'
Plugin 'ervandew/supertab'
Plugin 'edsono/vim-matchit.git'
Plugin 'kana/vim-textobj-user.git'
Plugin 'neomake/neomake.git'
Plugin 'nelstrom/vim-textobj-rubyblock.git'
Plugin 'nsf/gocode', {'rtp': 'vim/'}
Plugin 'danchoi/ri.vim'
Plugin 'derekwyatt/vim-scala'
Plugin 'kchmck/vim-coffee-script'
Plugin 'slim-template/vim-slim.git'
Plugin 'elixir-lang/vim-elixir'
Plugin 'c-brenn/phoenix.vim'
Plugin 'tpope/vim-projectionist'
Plugin 'lambdatoast/elm.vim.git'
Plugin 'FelikZ/ctrlp-py-matcher'
" vim-scripts repos
Plugin 'L9'
Plugin 'FuzzyFinder'
" non github repos
call vundle#end()
filetype plugin indent on " required!
runtime macros/matchit.vim
let g:solarized_termcolors=256
set t_Co=16
set background=dark
set shiftwidth=2
set softtabstop=2
set tabstop=2
let mapleader = ","
let g:ctrlp_max_height = 20
let g:ctrlp_match_func = { 'match': 'pymatcher#PyMatch' }
syn on
set nu
set ruler
let g:turbux_command_rspec = 'rspec'
colorscheme solarized
if executable('rg')
" Use ripgrep over grep
set grepprg=rg\ --nogroup\ --nocolor
" Use ripgrep in CtrlP for listing files
let g:ctrlp_user_command = 'rg --files %s'
" " Ripgrep is fast enough that CtrlP doesn't need to cache
let g:ctrlp_use_caching = 0
endif
" Remove trailing spaces
autocmd BufWritePre * %s/\s\+$//e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment