Is there a way to easily convert a series of tarballs of a source tree into a git repository?

Posted by Hotei on Stack Overflow See other posts from Stack Overflow or by Hotei
Published on 2010-05-03T17:19:29Z Indexed on 2010/05/03 17:38 UTC
Read the original article Hit count: 298

Filed under:

I'm new to git and I have a moderately large number of weekly tarballs from a long running project. Each tarball has on average a few hundred files in it. I'm looking for a git strategy that will allow me to add the expanded contents of each tarball to a new git repository, starting from version 1.001 and going through version 1.650. As of this stage of the project 99.5% of tarball(n) is just a copy of version(n-1) - in other words, a perfect candidate for git. The desired end result is to have only the master branch remaining at the end of the process.

I think I know git well enough to do this "by hand". As I understand it there is no possibility of a merge conflict since there will be no opportunity to change the master before the next version is added and committed. A shell script is my first guess, but I'm not sure how well bash will like it when git checkout branch_n gets processed while bash is executing in branch_n-1. For the purposes of this project the host environment is Ubuntu 10.4, resources available are 8 Gig RAM, 500 Gig Disk space free and 4 CPU processor at 3.ghz .

I don't need someone else to solve the problem but I could use a nudge in the right direction as to how a git expert would approach it. Any advice from someone who's "been there done that" would be appreciated.

Hotei

PS: I have looked at site's suggested "related questions" and found nothing relevant.

© Stack Overflow or respective owner

Related posts about git