
On Sun, Feb 12, 2012 at 04:14:26PM +0900, Julien Nitard wrote:
i had a developer run a script that was supposed to 'fix a few things' in the repo history. seemed to work ok on his test repo, but truncated commit messages in the production repo and shifted them by a few commits. this effectively rendered the repo useless.
Now I guess you've heard of backups, that's what they re supposed to protect from. Note that hooks are an entirely optional feature managed by the admin, not the developers.
Such damage may not be immediately noticeable and if it takes weeks/months/years to notice, reverting is not as easy as restoring from backups. In any way, if you need to perform history cleanup or other tasks as part of a migration or just sanitation of an existing repo, I would recommend taking a look at ESR's tool 'reposurgeon' [1]. [1] http://www.catb.org/esr/reposurgeon/ -- Lars Viklund | zao@acc.umu.se