Skip to content

Instantly share code, notes, and snippets.

@dctrwatson
Created October 4, 2013 19:19
Show Gist options
  • Save dctrwatson/6831227 to your computer and use it in GitHub Desktop.
Save dctrwatson/6831227 to your computer and use it in GitHub Desktop.
set runtimepath+=$GOROOT/misc/vim
set runtimepath+=$HOME/gocode/src/github.com/golang/lint/misc/vim
" Enable filetype plugin
filetype on
filetype plugin on
filetype plugin indent on
syntax on " Syntax highlighting
" python support
" --------------
autocmd FileType python setlocal expandtab shiftwidth=4 tabstop=8
\ formatoptions+=croq softtabstop=4 smartindent
\ cinwords=if,elif,else,for,while,try,except,finally,def,class,with
" YAML support
" ------------
autocmd FileType yaml setlocal expandtab shiftwidth=2 tabstop=8 softtabstop=2
autocmd BufNewFile,BufRead *.sls setlocal ft=yaml
" Lua support
" -----------
autocmd FileType lua setlocal shiftwidth=2 tabstop=2 softtabstop=2
" vim
" ---
autocmd FileType vim setlocal expandtab shiftwidth=2 tabstop=8 softtabstop=2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment