I rarely have to use mac OSX Vim for file editing, I usually ssh into remote machines which run ubuntu server or CentOS and there I’ve vim configured for syntax highlighting and other goodies.

But few times that I use Vim on mac, it makes my head hurt, no syntax highlighting by default? really?

To fix this you can do this:

Press the “i” key to switch vim to Insertion Mode, then enter these lines below the “set backspace=2” line:

Than press ESC, :x. And try sudo vi /usr/share/vim/vimrc again. You will see colors and your eyes will thank you.

Leave a Reply

Your email address will not be published. Required fields are marked *