Moving Old SourceForge Projects to GitHub

15 thoughts
last posted June 22, 2014, 2:55 p.m.
0
get stream as: markdown or atom
repost from freshmeat.net
0

This reminiscing now has me moving Redfoot and PyTREX over to github :-)

0

You can get the raw CVS repo with

rsync -av rsync://{project}.cvs.sourceforge.net/cvsroot/{project}/ {directory-to-put-cvs}
0

Attempt 1

In another directory, I tried (based on this):

git cvsimport -p x -v -d {directory-you-put-cvs} {directory-to-put-git}

but first I have to

brew install cvs

:-)

0

Even that doesn't work, though, as now I get:

$ git cvsimport -p x -v -d /Users/jtauber/Development/OpenSource/redfoot redfoot Initialized empty Git repository in /Users/jtauber/Development/OpenSource/redfoot.git/.git/ Running cvsps... Can't exec "cvsps": No such file or directory at /usr/local/Cellar/git/1.9.3/libexec/git-core/git-cvsimport line 756, <GEN0> line 2. Could not start cvsps: No such file or directory git cvsimport: fatal: cvsps reported error

0

Looks like

brew install cvsps

worked :-)

0

But now I get:

$ git cvsimport -p x -v -d /Users/jtauber/Development/OpenSource/redfoot redfoot fatal: Needed a single revision Branch 'origin' does not exist. Either use the correct '-o branch' option, or import to a new repository.

0

Reading the cvsimport man page makes me think I should try cvs2git instead.

0

Attempt 2

Downloaded csv2git (tarball from tigris linked above, no brew installing here).

Then ran

cvs2svn-2.4.0/cvs2git --blobfile=git-blob.dat --dumpfile=git-dump.dat --username={my-username} {directory-i-put-cvs}
0

Then I did a

mkdir {gitdir}
git init {gitdir}
cd {gitdir}

Then

cat ../git-blob.dat ../git-dump.dat | git fast-import
git checkout master
0

While that seems to contain all the commits, we don't have the author email addresses so pushing to GitHub doesn't make a link with the right user accounts.

0

Seems the key is customizing the cvs2git options file.

0

Attempt 3

Copied the example options file into my own cvs2git.options file and edited the author_transforms dictionary and the hardcoded test-data/main-cvsrepos.

0

Did

mkdir {gitdir}
git init {gitdir}
cd {gitdir}

again.

0

And finally:

cat ../cvs2svn-tmp/git-blob.dat ../cvs2svn-tmp/git-dump.dat | git fast-import
git checkout master