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

resolving tree conflicts (overview)

From: Stephen Butler <sbutler_at_elego.de>
Date: Mon, 03 Nov 2008 18:45:56 +0100

Hello tree conflict fans,

While hacking on svn resolve, I made a list of tree conflict types
distinguished by incoming "action" and local "reason", printed below
as "(action:reason)". For each type, I describe what I think the
effect of each --accept option should be. Operation-specific parts
are in square brackets.

Please have a look and make corrections/comments inline.

Thanks,
Steve

(*:*)

working: Do nothing (aside from removing the item's tree conflict
          status).

(edit:delete)

base: Revert the deletion of the victim_at_BASE.

mine-full: [Update: Apply incoming chagnes to the victim.] [Merge:
            Do nothing.]

theirs-full: Undo the deletion and update the victim (without
              triggering another tree conflict on the victim).

(edit:missing)

base: Restore victim_at_BASE in the working copy. [Update: Finish
       updating the victim. Apply to the victim the reverse the
       incoming changes.]

mine-full: [Update: Apply incoming changes to the victim.] Delete the
            victim. We assume the victim is missing because the user
            wants to get rid of it.

theirs-full: [Update: Update the victim to the target revision.]
              [Merge: Delete the victim. Add-with-history the
              merge-right counterpart of the victim.]

(edit:unknown) [occurs during merge only]

base: Do nothing.

mine-full: Do nothing.

theirs-full: Add-with-history the merge-right counterpart of the
              victim.

(delete:edit)

base: [Update: Finish deleting the victim. Add-with-history the
       victim_at_BASE without local mods.] [Merge: Revert local mods and
       delete the victim.]

mine-full: [Update: Finish deleting the victim. Add-with-history the
            victim_at_BASE including local mods.] [Merge: Do nothing.]

theirs-full: [Update: Finish deleting the victim. "rm" the
              unversioned victim.] [Merge: Delete the victim.]

(delete:delete)
(delete:missing)
(delete:unknown) [occurs during merge only]

base: [Update: Add-with-history the victim_at_BASE.] [Merge:

mine-full: [Update: Finish deleting the victim.]

theirs-full: [Update: Finish deleting the victim.]

(add:add) [occurs only if victim is locally added with history]

base: Revert the victim and "rm" the unversioned item. Finish adding
       the new item, and then delete it.

mine-full: [Update: Finish updating the victim, resolving any text or
            prop conflicts with '--mine-full'. Ideally, we would also
            delete any subtrees newly added by the operation.] [Merge:
            Do nothing.]

theirs-full: Revert the victim and "rm" the unversioned item.
              [Update: Finish adding the new item.] [Merge:
              Add-with-history the merge-right counterpart of the
              victim.]

Note:

We'd like to handle obstructions as tree conflicts, but that looks
rather tricky. Should we disallow --mine-full for victims that are
obstructions? Or maybe disallow both --mine-full and --theirs-full.

(add:obstructed)

base: Revert the victim if it is versioned. "rm" the unversioned
       victim. [Update: Finish adding the new item, and then delete it.]

mine-full: Error. Ideally, we would revert the obstructing victim,
             move it to a temp location, finish the update, then apply
             a diff from the new item to the obstructing victim (i.e.,
             replace the new item with the victim). But a dir->file or
             file->dir replacement can't be done in a single commit.

theirs-full: Revert the victim and "rm" the unversioned item.
              [Update: Finish adding the new item.] [Merge: Hmm, we'd
              have to re-run the merge(s) for the victim subtree.
              Don't know if that's feasible.]

(edit:obstructed)

base: Revert the victim if it is versioned. "rm" the unversioned
       victim. Finish adding the new item, and then delete it.

mine-full: Error. See (add:obstructed). Maybe tell the user that
            storing symlinks in a version control system is rather
            silly.

theirs-full: Revert the victim and "rm" the unversioned item. Finish

-- 
Stephen Butler | Software Developer
elego Software Solutions GmbH
Gustav-Meyer-Allee 25 | 13355 Berlin | Germany
fon: +49 30 2345 8696 | mobile: +49 163 25 45 015
fax: +49 30 2345 8695 | http://www.elegosoft.com
Geschäftsführer: Olaf Wagner | Sitz der Gesellschaft: Berlin
Amtsgericht Charlottenburg HRB 77719 | USt-IdNr: DE163214194
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-11-03 18:46:06 CET

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.