Gitting git-svn working on mac


I woke up fired up and ready to try git; unfortunately, it is three hours later and I’m just gitting started. The problem was getting git-svn to work. Despite the numerous posts including: post1 post2 post3 and post4 I absolutely could not get it to work. Finally, here are two techniques that worked for me:
Port Method
sudo port install subversion-perlbindings
sudo port install git-core

or Method2

follow Fraser Spiers post


export PERL5LIB=”/opt/subversion/lib/svn-perl:$PERL5LIb”

In other words, the package installs the subversion perl bindings in /opt/subversion/lib/svn-perl not /usr/local/lib/svn-perl.

Time to start gitting it done!


4 Responses to “Gitting git-svn working on mac”

  1. 1 Gabriel Gosselin

    I finally took the plunge and installed MacPorts. After a whole lot of downloading and compiling dependencies I was sure

    sudo port install git-core +svn

    Would deliver the coveted git-svn.
    I too was getting the “Command not found” error. Then I looked around a bit and found that it is, in fact, present at:


    So I made a symlink to that (since there are a LOT of git- libs and I don’t want them all loading):

    sudo ln -s /opt/local/libexec/git-core/git-svn /opt/local/bin/git-svn

    Hope that helps a few others. Cheers!

    • 2 Eric Barr

      I was just today taking this same plunge and running up against the same issue as Gabriel above. It turns out the issue is outdated documentation widely spread across the web. Instead of invoking a separate executable you can use the git command now for git-svn work:

      git svn init

      Hope that helps those hitting this same wall 🙂

  2. Thanks for the notes guys, I got this up and working pretty quickly.

  3. Thanks for the help – this was the last piece missing for me – I thought git-svn was some other download but looks like it just comes with git. Nice. Thanks again.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: