[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: Re: What to do when stuff gets committed to trunk when it shouldn't?

From: Mark Shead <sheadm_at_optimalinternet.com>
Date: 2005-11-22 20:09:19 CET

> Great! That's what I did. It was a lot easier than I thought ... I was
> making the problem more complicated in my head. I originally wanted to
> back out the bad revisions in trunk completely. After reading a bit I
> realized that's not possible (Subversion doesn't delete things from
> history). After thinking about it for a bit, I realized that it
doesn't
> really matter that the additional entries are in the log -- it doesn't
> prevent anyone from doing anything. Now if someone had committed a
> secret file, I'm not sure what I'd do. Is there anything that can be
> done aside from restore from backup (and a bunch of work to get
> subsequent changes checked back in)?

There is actually a way to back out changes completely. Generally the
only reason for doing this is if someone commits some very large files
inadvertently and you don't want your back to go from 50MB to 15GB with
a few files that shouldn't be in there anyway.

Basically you do a "svnadmin dump" all the way up to where the changes
you don't want begin. Then you do an "svnadmin load" to put it back in
a new repository. If you need to remove some files that were added in
the middle, you can dump one range of revisions before the change and
then dump the range of revisions after the change. You can then load
them both back into the new repository.

Normally you won't need to do this, but it is worth keeping in mind just
in case someone commits something huge by accident.

--Mark

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Nov 22 20:11:59 2005

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.