Skip to content

Instantly share code, notes, and snippets.

@fearphage
Created September 18, 2011 21:38
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 fearphage/1225587 to your computer and use it in GitHub Desktop.
Save fearphage/1225587 to your computer and use it in GitHub Desktop.
filetype plugin indent on
set expandtab
set smartindent
set relativenumber
set textwidth=79
set colorcolumn=81
set nofoldenable
set hlsearch
set incsearch
" nnoremap <esc> :noh<return><esc>
"nnoremap <CR> :noh<CR><CR>
autocmd BufWritePre * :%s/\s\+$//e
" CSS
autocmd FileType css set shiftwidth=2 tabstop=2 softtabstop=2
" HTML
autocmd FileType html set shiftwidth=2 tabstop=2 softtabstop=2
" Javascript
autocmd FileType javascript set shiftwidth=2 tabstop=2 softtabstop=2
" VIM
autocmd FileType vim set shiftwidth=2 tabstop=2 softtabstop=2
" Python stuff..
au FileType python set tabstop=4
au FileType python set shiftwidth=4
au FileType python setl softtabstop=4
"autocmd FileType python compiler pylint
highlight BadWhitespace ctermbg=red guibg=red
au BufRead,BufNewFile *.py,*.pyw match BadWhitespace /^\t\+/
au BufRead,BufNewFile *.py,*.pyw,*.c,*.h,*.js match BadWhitespace /\s\+$/
"highlight SpellBad term=reverse ctermbg=0
" Node stuff
au BufNewFile,BufRead *.ejs set filetype=html
au BufRead,BufNewFile *.coffee set filetype=coffee
autocmd FileType coffee compiler espresso
" Actionscript
au BufNewFile,BufRead *.as set filetype=actionscript
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment