Created
February 21, 2012 11:29
-
-
Save oxyc/1875991 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function! SetWPConfig () | |
setlocal shiftwidth=4 softtabstop=4 tabstop=4 noexpandtab | |
setlocal listchars=trail:· | |
endfunction | |
function! SetDrupalConfig () | |
setlocal shiftwidth=2 softtabstop=2 tabstop=2 expandtab | |
setlocal listchars=tab:▸\ ,trail:· | |
endfunction | |
" Wordpress files | |
au BufRead,BufNewFile */wp-content/*.php call SetWPConfig() | |
" Drupal files | |
augroup module | |
au BufRead,BufNewFile *.module set filetype=php | call SetDrupalConfig() | |
au BufRead,BufNewFile *.install set filetype=php | call SetDrupalConfig() | |
au BufRead,BufNewFile *.test set filetype=php | call SetDrupalConfig() | |
au BufRead,BufNewFile */sites/all/*.php call SetDrupalConfig() | |
augroup END |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment