Color code for vi on terminal on Mac?
Add the following to your ~/.vimrc:

filetype plugin indent on
set term=builtin_ansi
syntax on


If you’re using iTerm, use this instead of line 2:

set term=xterm-256color