bling / dotvim

lean & mean vim distribution
428 stars 82 forks source link

bling.vim

A highly tuned vim distribution that will blow your socks off!

introduction

this is my personal vim distribution that i have tweaked over time and evolved from a simple vanilla vimrc configuration to a full-blown distribution that it is today.

while it is very easy to install this and get up and running on a brand new machine (a use case i have), i recommend that you do not install this unless you fully understand everything that's going on inside. scan it for tips and tricks, or fork and customize it for your needs.

installation

  1. clone this repository into your ~/.vim directory
  2. git submodule init && git submodule update
  3. mv ~/.vimrc ~/.vimrc.backup
  4. create the following shim and save it as ~/.vimrc:
let g:dotvim_settings = {}
let g:dotvim_settings.version = 2
source ~/.vim/vimrc
  1. startup vim and dein will detect and ask you install any missing plugins. you can also manually initiate this with :call dein#install()
  2. done!

versioning

the g:dotvim_settings.version is a simple version number which is manually edited. it is used to detect whether significant breaking changes have been introduced so that users of the distribution can be notified accordingly.

customization

" this is the bare minimum
let g:dotvim_settings = {}
let g:dotvim_settings.version = 1

" here are some basic customizations, please refer to the top of the vimrc file for all possible options
let g:dotvim_settings.default_indent = 3
let g:dotvim_settings.max_column = 80
let g:dotvim_settings.colorscheme = 'my_awesome_colorscheme'

" change the default directory where all miscellaneous persistent files go
let g:dotvim_settings.cache_dir = "/some/place/else"

" by default, language specific plugins are not loaded.  this can be changed with the following:
let g:dotvim_settings.plugin_groups_exclude = ['ruby','python']

" if there are groups you want always loaded, you can use this:
let g:dotvim_settings.plugin_groups_include = ['go']

" alternatively, you can set this variable to load exactly what you want
let g:dotvim_settings.plugin_groups = ['core','web']

" if there is a particular plugin you don't like, you can define this variable to disable them entirely
let g:dotvim_settings.disabled_plugins=['vim-foo','vim-bar']

" finally, load the distribution
source ~/.vim/vimrc

" anything defined here are simply overrides
set wildignore+=\*/node_modules/\*
set guifont=Wingdings:h10

autocomplete

this distribution will pick one of three combinations, in the following priority:

  1. neocomplete + neosnippet if you have lua enabled.
  2. youcompleteme + ultisnips if you have compiled YCM.
  3. neocomplcache + neosnippet if you only have vimscript available

this can be overridden with g:dotvim_settings.autocomplete_method

standard modifications

mappings

insert mode

normal mode

visual mode

plugins

unite.vim

bufkill.vim

sneak.vim

easygrep

fugitive

gitv

unimpaired

nerdtree

tcomment

ctrlp

nrrwrgn

tabular

gist

emmet

undotree

youcompleteme/ultisnips

neocomplcache/neosnippet

vimshell

vim-multiple-cursors

and some more plugins

and even more plugins...

credits

i wanted to give special thanks to all of the people who worked on the following projects, or people simply posted their vim distributions, because i learned a lot and took many ideas and incorporated them into my configuration.

license

WTFPL

changelog