Skip to end of metadata
Go to start of metadata

This is what you do to create a release repository with old history cut off:

git checkout --orphan temp <hash>

where <hash> is the hash of your new base commit

git commit -m "Log message"
git rebase --onto temp <hash> master
git branch -D temp

 

This will result in a "master" branch that has all the history from before <hash> stripped away, but everything since then kept

 

Source: http://stackoverflow.com/questions/4515580/how-do-i-remove-the-old-history-from-a-git-repository

  • No labels