I found myself doing a lot of “:syntax on” when using vim. Then I was like, maybe I can add that to the setting file… So, it turns out it’s hecka simple. Just do the following:
vi ~/.vimrc
Then put in the line “syntax on” somewhere in the file. Then you are done! Next time when you open any source files, syntax will be turned on automatically!
Apparently there are a lot more settings for you. Take a look at here.