Hello, A moron has checked in a DVD iso into subversion. How can I undo the damage, and make the repo a sensible size again? Also, is there a cunning way to get subversion to say: "Oi! Moron! This file is huge, you can't check it in!" ? S.
On Fri, Nov 13, 2009 at 4:55 PM, Stephen Nelson-Smith < stephen at atalanta-systems.com> wrote:> Hello, > > A moron has checked in a DVD iso into subversion. > > How can I undo the damage, and make the repo a sensible size again? > > Also, is there a cunning way to get subversion to say: "Oi! Moron! > This file is huge, you can't check it in!" ? > > S. > _______________________________________________ > CentOS mailing list > CentOS at centos.org > http://lists.centos.org/mailman/listinfo/centos >yum can try do that: svnadmin dump -r x:y repos_path>svnproject (where x:y is revisions numbers. for y use revision before dvd) then delete that project and exactly don't remember, but probably smth like that: svnadmin load REPOS_PATH<svnproject of course it is better to play around with test projects for better understand look into svnadmin help, or svn book -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.centos.org/pipermail/centos/attachments/20091113/9f885c27/attachment-0003.html>
On Fri, Nov 13, 2009 at 02:55:24PM +0000, Stephen Nelson-Smith wrote:> A moron has checked in a DVD iso into subversion. > > How can I undo the damage, and make the repo a sensible size again?I fully understand the grief. Out of the top of my head you can use 'snvadmin dump' to get an (even larger) dump of the repo as a single file. Then feed it to svndumpfiler to reconstruct the repo and filter out the excess commits. For me it worked as advertised.> Also, is there a cunning way to get subversion to say: "Oi! Moron! > This file is huge, you can't check it in!" ?There are so called hooks server side that get triggered by the check in/out/etc. It may be possible to look at the size of the changes and reject the operation based on thresholds. I have never tried that, although. Hope this helps. Mihai
From: Stephen Nelson-Smith <stephen at atalanta-systems.com>> A moron has checked in a DVD iso into subversion. > How can I undo the damage, and make the repo a sensible size again? > Also, is there a cunning way to get subversion to say: "Oi! Moron! > This file is huge, you can't check it in!" ?I also think dump_previousrevision+delete+reload might be necessary... I think you could maybe use a pre hook script to prevent it in the future: See /path/to/mysvn/hooks/pre-commit.tmpl JD