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

Re: 'svn revert' vs. 'svn resolve'

From: Greg Stein <gstein_at_lyra.org>
Date: 2003-06-11 01:03:42 CEST

On Tue, Jun 10, 2003 at 04:18:49PM -0500, kfogel@collab.net wrote:
> Greg Stein <gstein@lyra.org> writes:
> > last saved." It works perfect, so I'd agree that the command name shouldn't
> > change. Personally, I would suggest leaving the .mine file if you revert a
> > conflicted file. It's safe, easy to explain, and it isn't hard to clean
> > those up.
>
> This could work, but we need to figure it out in more detail. Calling
> it ".mine" overloads that suffix.

I initially thought "no", but now agree...

> When you update and get a conflict, four files result (right?):

Yup.

> 1. your working file 'foo' gets conflict markers
> 2. 'foo.r6' (say) is the old base revision of the file
> 3. 'foo.r8' (say) is the new base revision of the file
> 4. 'foo.mine' is the old working file, w/o conflict markers

Right.

> If you meant to type "resolve" but typed "revert" instead, then you
> intended for all of the above to go away except the working file. So
> to be safe, reverting a conflicted file would preserve the working
> file -- but under what name? 'foo.mine' already means something
> different...

[ note: I read this as 'preserve the working file in place' rather than
  'save it off' ... but my brain catches up below ]

But that doesn't work. If you *meant* to type 'revert', then you want the
working file to be foo.r8 (i.e. the current text-base contents). I don't
think we want to alter the behavior of 'revert' in the presence of a
conflict. That just seems a bit too squishy and special-cased for me.

Thus, the working file returns to foo.r8.

Oh. I was about to say that leaving 'foo.mine' was the right operation, but
that isn't the case. If the text-base was still at r6, then *yes* -- you
could continue working with foo.mine since it was "locally branched" (if you
will) from r6. But the text-base has moved up to r8, so simply shoving
foo.mine over the top of the working file would be bad. You'd lose the r6:r8
changes.

> How about "foo.merged"? Any other ideas?

Yup. We gotta pick a new name, and the working file gets moved to that new
name. Just leaving the .mine around isn't correct behavior.

Hunh. "foo.merged" might be okay. Realize that there will also be some
"unique ID" component in that file name, too. (just like the .mine and other
conflict files)

> I don't necessarily think renaming "resolve" is better than this other
> solution; just would like to have it fully described before we decide.

Good thing :-)

Cheers,
-g

-- 
Greg Stein, http://www.lyra.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Jun 11 01:00:14 2003

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

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