I know this might be more appropriate at Ask Different, but as I tried adding tags there, there was no vim
tag, only macvim
. So I figured I might g
A note to romainl's answer: aliases don't work together with sudo because only the first word is checked on aliases. To change this add another alias to your .profile / .bashrc:
alias sudo='sudo '
With this change sudo vim
will behave as expected!
Like Eric, I used homebrew, but I used the default recipe. So:
brew install mercurial
brew install vim
And after restarting the terminal homebrew's vim should be the default. If not, you should update your $PATH
so that /usr/local/bin
is before /usr/bin
. E.g. add the following to your .profile
:
export PATH=/usr/local/bin:$PATH