aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--vimrc13
1 files changed, 13 insertions, 0 deletions
diff --git a/vimrc b/vimrc
index c7e9142..8614fd5 100644
--- a/vimrc
+++ b/vimrc
@@ -85,6 +85,11 @@
" * Set ignorecase and smartcase
" * Add file encoding to statusline
"
+" 2014.04.28:
+" * Add augroup for custom syntax highlighting by filetype
+" * Add autocmd to set .json files to use JavaScript syntax highlighting
+" and have a json filetype
+"
" Pathogen
@@ -357,6 +362,14 @@ command! -nargs=* Wrap set wrap linebreak nolist
" autocmd bufwritepost .vimrc source $MYVIMRC
" endif
+" Filetype syntax highlighting
+augroup filetype_syntax_highlighting
+ autocmd!
+
+ " Set JSON files to JavaScript syntax
+ autocmd BufRead,BufNewFile *.json set filetype=json syntax=javascript
+augroup END
+
" Project Settings