Domanda

Using the merge functionality in SVN (through TortoiseSVN) since a few month, I have the feeling that SVN reports way too often that a conflict occurs.

So I am looking for a way to make (Tortoise)SVN more often resolve conflicts automatically without my user-interaction.

I'm aware of similar questions and the fact that you can replace the diff viewer and merge tool with external ones:

enter image description here

From my understanding these tools chain-in too late; they are getting called by SVN/TortoiseSVN when the internal algorithm already detected an unresovable conflict.

So my questions are:

  • Is my assumption of the behaviour (internal merge algorithm, external merge tools) correct?
  • Is there a way to improve the internal merge algorithm by (e.g. paid) tools?

(I'm using VisualSVN Server and V1.7 repositories, in case that matters)

È stato utile?

Soluzione

Firstly, its nothing to do with Tortoise - that's just an extremely nice GUI on top of the SVN system.

Now, maybe you have lots of merges that actually need human attention. If so, moving to something like git or Mercurial will not help you one bit - neither of those can tell what you really meant, just like SVN cannot tell.

You can check out the way SVN does its merge algorithm, by reading the documentation. FYI v1.8 has a few tweaks to it that should mean there's much less manual decision making when doing reintegration merges - it just does it automatically now, so if you've been doing the special feature-branch style merges and have been doing it wrong, then it won't complain anymore. They've been working on merging for the last 2 versions now, improving it continually not only with the mergeinfo, but with features like move so it can tell a file isn't new or deleted so reducing any tree conflict type merges.

Altri suggerimenti

It's difficult to speculate on the context, but conflicts being found is unlikely to have anything to do with TortoiseSVN in particular and more to do with just svn in general. As mvp says, git would be better (heh) but have you looked at the --reintegrate flag for merge? Not sure how you could use it from TortoiseSVN directly, but it's proved very useful for me in reducing conflicts.

Edit View the 'advanced merging' tutorial here

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top