Results 1 to 4 of 4
  1. #1
    Join Date
    Sep 2013
    Posts
    2

    Question 3-way diff view of conflicts

    Hi,

    Thank you for BC3. It's a great tool!

    I am using SVN 1.7 and use BC3 3-way diff in order to resolve conflicts upon merging in the following method:
    LEFT=BASE version
    RIGHT=MINE (local) version
    CENTER=THEIR version
    RESULT=SVN's <target file>.tmp.merged file (SVN expects this file to contain my resolutions prior to hitting 'r' - resolved)

    The merge direction is "THEIRS"-->"MINE".

    There are problems, though:
    (1)
    SVN applies its own merge and creates the .tmp.merged file for the user's edit. But when loading .tmp.merged as the result of the 3-way diff, BC3 overrides SVN's changes and shows its own resolution (preferring BASE, which is almost always the wrong choice). So instead of reviewing only conflicts discovered by SVN, the user goes over the entire differences set and selects MINE or THEIRS between them, one by one.
    SVN already did it and now the user repeats it. It creates more work and is prone to mistakes.

    (2)
    In order to bypass the problem described in (1), I loaded these files in BC3:

    LEFT=SVN's <target file>.tmp.merged file
    RIGHT=MINE (local) version
    CENTER=THEIR version
    RESULT=SVN's <target file>.tmp.merged file

    As you can see, the BC3 LEFT and RESULT windows view the same file, which is the SVN's merge resolution file. It holds the merged MINE and THEIRS changes and has notations where text conflicts are.

    I noticed there are differences between RESULT and LEFT windows. These are changes that appear only in LEFT and CENTER windows. These changes are not written in the RESULT window unless I take them from LEFT or CENTER, even if I use the -favorleft switch.


    Any idea of how to solve (1) and why my workaround in (2) is not working with BC3?

    Much thanks!
    Ohn Tsarfati

  2. #2
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,384

    Default

    Hello,

    BC3 currently requires that the Center pane be the Base/Ancestor. The merge logic used (favor, etc) expects this. Left and Right are Yours/Theirs.

    How does this work for you?
    Aaron P Scooter Software

  3. #3
    Join Date
    Sep 2013
    Posts
    2

    Default

    Great! Thanks! So simple.

    But for the other issue now - BC3's merge overrides the SVN tool merge. In theory, if I edited the ".tmp.merged" file while stopping on a conflict, I could see a different result than what BC3 shows.

    Do you agree? Can you resolve this?

  4. #4
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,384

    Default

    A conflict would not be automatically brought down into the Output pane, and only the output pane is going to be saved into its target. Have both "left" and "output" be the same file does not mean they will show the same content. The Left will show the content of the file, while the Output will show the results of the merge from all three inputs. The file path of the Output does not impact the content shown in the Output pane; it is only used as the target of the save operation. If you perform a Save of the Output, this would update that target file, and updating it would overwrite then refresh the content in the Left pane if it is the same file.

    In summary, the content shown in the Output pane is auto-generated based on the 3 input panes, and is not related to its eventual save target (in this case, the same file location as the Left pane).

    We have several SVN based examples in a KB article on our website, such as TortoiseSVN. Here is a direct link to the base SVN section:
    http://www.scootersoftware.com/suppo...?zz=kb_vcs#svn

    The expected configuration is to have the Left and Right configured to be Yours and Theirs, the Center is the Ancestor, and the Output pane is the savetarget of the merge of these 3 files.
    Aaron P Scooter Software

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •