Add script which can fix the broken commits in this repository

Note the resulting hashes are (of course) different.
Merge pull request #117 from djs55/fix-broken-commits

Add script which can fix the broken commits in this repository