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

Re: feature request: UNDO

From: Karl Fogel <kfogel_at_red-bean.com>
Date: 2007-11-05 23:41:29 CET

"Erik Volz" <erik.volz@gmail.com> writes:
> Subversion would be a lot easier to use if there was a simple UNDO
> command that reversed whatever your last action was. Example: I
> recently accidentally imported a bunch of files into the trunk of my
> repository. Deleting them all required a little script. Browsing
> through the archives, I see several people had the same problem.
>
> Since svn logs everything, an undo command would be easy, right?

It's hard to know exactly what to undo. For example:

   $ cd working-copy
   $ svn switch some-url some-subdir
   $ edit some/path/some-file
   $ svn merge src1 src2 another/path/dst
   $ edit-to-resolve-conflicts-from-merge another/path/dst/conflicted-file
   $ edit yet-another-path

Okay, now:

   $ svn undo

What should it undo? Just the plain edits? The plain edits and the
conflict-resolution edit, but not the merge? All the edits *and* the
merge? The edits, the merge, *and* the switch? :-)

This is just one example. I could probably come up with weird edge
cases all day. It's quite likely that the behavior of 'svn undo'
would be counterintuitive to a lot of users a lot of the time. Maybe
we could find a consistent and predictable behavior, but it wouldn't
be trivial.

-Karl

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Mon Nov 5 23:41:50 2007

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.