Getting a git revision number from an old subversion rev number

Hi all,

I have been using an old version of the gnuradio trunk. I wanted to
check out that old version again, but I noticed that the switch over
to git has been completed and the subversion repository has been taken
down. Although, the git repository still looks like it has old
versions of the code back to 2006. Is there any way to convert a
revision number from the subversion repository into a git revision
number? Oh, and by the way, I also have the “Last Changed Date”
corresponding to the old version of the code that I would like to
check out, if that is relevant.

I apologize if someone has already asked this question, but I wasn’t
able to find this answer while searching through the mailing list
archives. Thanks for your help.

On Thu, Jan 21, 2010 at 12:43 PM, Ketan M. [email protected]
wrote:

Hi all,

I have been using an old version of the gnuradio trunk. I wanted to
check out that old version again, but I noticed that the switch over
to git has been completed and the subversion repository has been taken
down. Although, the git repository still looks like it has old
versions of the code back to 2006. Is there any way to convert a
revision number from the subversion repository into a git revision
number?

The subversion imported commits have the revision number at the end of
the description in the “git-svn-id” line. For example, you can create
and checkout a new branch with svn revision 10184 by doing the
following.

Find the commit hash from the git-svn-id.

git log --grep=git-svn-id.*@10184

Create and checkout a new branch named r10184 from the commit hash.

git checkout -b r10184 cd7b07f0140ddff6

That works for me, and I’m sure there are other ways as well. Hope that
helps.

Thomas

On Thu, Jan 21, 2010 at 02:22:39PM -0500, Thomas T. wrote:

git checkout -b r10184 cd7b07f0140ddff6

That works for me, and I’m sure there are other ways as well. Hope that helps.

Thomas

Cool! Thanks!

Eric