I have a project that I want to put onto Git. We have many old ‘zip’ snapshots of the project that can be used to create the basis of the putative historical lineage, plus a few even older bits, many I’ve still to ‘find’, that I’d still like to add to the history I build.
It isn’t too hard to create a lineage from the newer zips [copy, commit, copy, commit, .. etc.] immediately, but how to graft(?) on the older history retrospectively? I’d like the history to look like I entered them chronologically, so some sort of re-write would probably be required.
Because the team is very small and co-located we can easily handle the change over from the draft version to the ‘proper’ version, so this is a practical exercise in getting started, and finessing the ‘still to find’ portions once everyone has started using git (I’d rather we were using git that waiting till sufficient ‘history as found ;-).
So the question is how do I retrospectively graft on the early history, and then re-write the whole repo so the graft doesn’t show? I know this will re-write all the commit SHA1 IDs.
You probably want to do what is described here:
https://softwareengineering.stackexchange.com/questions/33868/script-tool-to-import-series-of-snapshots-each-being-a-new-edition-into-git-po
but add the
--dateoption togit commitso that it will set whatever date comes from the zip file.