vimblog.vim on MacVim

June 6th, 2009

I was contacted via Twitter for some support on getting vimblog.vim to work on MacVim, on Mac OSX Leopard. The unique problem is that it must be compiled with Ruby interpreter support. So here is a quick guide to do it, building from Macvim git repository:

# select a folder where to build the aplication on your area:
cd to_your_workingspace_apps_folder
# get (clone) MacVim from its MacVim.git repository:
$ git clone git://github.com/b4winckler/macvim.git
$ cd MacVim
$ cd src
# now let us configure it for macvim gui and for +Ruby (I’ll add +Python and +Perl) support:
$./configure --enable-gui=macvim --enable-rubyinterp --enable-perlinterp --enable-pythoninterp --with-ruby-command=/Users/pedro/.rvm/rubies/ruby-1.8.7-p357/
$ make
# Success ? Let’s build the MacVim.app
$ cd MacVim
$ xcodebuild
# Sucess ? Let’s try it…
$ open build/Release/MacVim.app
# now lets copy vimblog to $HOME
$ cp $HOME/Downloads/vimblog.vim $HOME/.vim/plugin
# insert your credentials
# now test the existence of the script. Run MacVim and execute
:B + TAB
# you shoud get code completion for the Blog command.
# get the 10 most recent articles
:Blog rp

if you get problems, before another build, do a:
$ make distclean

Screenshots: jump to flickr macvim window jump to flickr building space

Update
I wiped out the default OSX Ruby and use only RVM Rubies. So now to compile, one needs to specify the exact ruby interpreter. It’s updated on the ./configure statement above.
Update
One can use the default Ruby used by RVM, using the default rubies path like below:
$./configure --enable-gui=macvim --enable-rubyinterp --enable-perlinterp --enable-pythoninterp --with-ruby-command=/Users/pedro/.rvm/rubies/default/
Update
removed the old download place, and updated to the new one (above)


2 Comments to “vimblog.vim on MacVim”


  1. mitja said:

    Thanks for the post, got it to compile.

    One issue I had is that the make failed whenever I tried to compile with Ruby on my MBP. Turns out gcc was the -arch ppc flag to the Makefile. Here is how to get it work:

    http://www.mail-archive.com/vim_mac@googlegroups.com/msg00606.html


  2. dmitry kichenko » Blog Archive » Getting FuzzyFinder_TextMate to work again said:

    […] The official binary of MacVim does not come with Ruby support compiled in. Assuming you’ve got Xcode though, it’s quite trivial to compile it yourself. […]

Leave a Reply