Vim supports a whole lot of features, however I've listed the basic config to get started with development in rails.
~/.vimrc
~/.vimrc
set nocompatible " We're running Vim, not Vi!Apart from this, you can also tweek any config under /etc/vim/vimrc , based on your preference.
syntax on " Enable syntax highlighting
filetype plugin indent on " Enable filetype-specific indenting and plugins
" Load matchit (% to bounce from do to end, etc.)
runtime! macros/matchit.vim
augroup myfiletypes
" Clear old autocmds in group
autocmd!
" autoindent with two spaces, always expand tabs
autocmd FileType ruby,eruby,yaml set ai sw=2 sts=2 et
augroup END
nmap <leader>rci :%!ruby-code-indenter<cr>
No comments:
Post a Comment