Saturday, February 11, 2012

Latest Vim for Mac OS X

The 7.3 version on Vim that comes with Mac OS X is getting old. It doesn't support some of the latest features and you would not be able to use some of the interpeters like ruby that is not supported out of the box.
One way to improve this is to install MacVim, another one is to recompile Vim from source code configuring some of the missing features. Here is how I configured it for myself for example:

* Get source code:
> hg clone https://vim.googlecode.com/hg/ vim

* Compile & Install:
> cd vim
> ./configure --enable-luainterp --enable-perlinterp --enable-pythoninterp --enable-tclinterp --enable-rubyinterp --enable-cscope
> make -j4
> make install

By default everything will be installed user /usr/local, so make sure that /user/local/bin is specified before /usr/bin in your PATH environment variable, or use a different prefix for ./configure  that already specified before /usr/bin path for example --prefix=/opt/local.

After these steps I got Vim 7.3.434 on my machine.

No comments: