What is the proper way to do a Subversion merge in Eclipse?

前端 未结 9 1018
深忆病人
深忆病人 2021-01-30 11:58

I\'m pretty used to how to do CVS merges in Eclipse, and I\'m otherwise happy with the way that both Subclipse and Subversive work with the SVN repository, but I\'m not quite su

相关标签:
9条回答
  • 2021-01-30 12:34

    The one thing that syncrhonize view in eclipse lacks is check-in capability. In Team synchronization view I can view all my changes and resolve conflicts, so it would be rather intuitive to check-in right there instead of going back to java view and do check-in.

    0 讨论(0)
  • 2021-01-30 12:35

    I landed here because I was looking for a way to merge in an external merge editor (KDIFF3) but start the merge from eclipse. I wasn't satisfied with the answers provided above. So here is ho to configure kdiff3 as merge and diff editor for SVN in eclipse:

    go to Windows -> Preferences → Team -> SVN -> Diff Viewer Add a new config (add button): Extension or mimetype: * - if you wish you can specify different mimetypes for different editors, I didn't need that thus the alquantor.

    Diff: Program path C:\Program Files\KDiff3\kdiff3.exe (or wherever you have your merge editor - sry for the windows path, feel free to add a linux version in the comments or edit this answer.)

    Arguments: ${base} ${mine} ${theirs}

    Merge: Program path C:\Program Files\KDiff3\kdiff3.exe

    Arguments: ${base} ${mine} ${theirs} -o ${merged}

    This will probably work as well for other merge editors, but with a different argument syntax (figure it out an let us know :) ).

    The usage is as usual (team->edit conflicts) for merging and compare->foo for the diff view.

    Cheers

    0 讨论(0)
  • 2021-01-30 12:37

    Firstly, if you are seeing ">>>>>" and such in your files when you view them in Eclipse, this probably means that you are not looking at the file with the proper compare editor. Try right-clicking on the file in the Project view or Synchronize view and selecting "Edit Conflicts" to bring up a compare editor that will show you the conflicting regions graphically rather than as text. Note that the compare editor that comes up for "Edit Conflicts" is different from the one that you get when you just doubleclick on a file in the Synchronize view -- the doublieclick compare editor shows the differences between your current file and the way it existed when you last checked it out or updated it, while the Edit Conflicts compare dialog shows the differences between two sources of changes (for instance, the changes you merged versus the changes that existed in your workspace before you merged).

    Secondly, you may wish to be aware of a bug in some versions of the Eclipse subversive plugin which causes all files that accepted merge changes to be incorrectly marked as having conflicts. This bug has been fixed, but a lot of people don't seem to have updated to get the fix yet. Further details here:

    https://bugs.eclipse.org/bugs/show_bug.cgi?id=312585

    0 讨论(0)
提交回复
热议问题