Oliver Nassar

Getting VIM to show the line numbers be default (in OSX and Ubuntu 10.10)

May 03, 2011

I always want to see the line-numbers when editing something from VIM, and don't like having to type :set number each time; thus..

In OSX, edit the vim config file located at:

/usr/share/vim/vimrc

Add the following at the end of the file:

" Custom Config Options
set number

That's it. For Ubuntu 10.10 (Maverick Meerkat), the file is located at:

/etc/vim/vimrc

Same deal there. Hope that saves someone some time.