[darcs-users] Merge and conflicts
droundy at abridgegame.org
Fri Mar 5 12:14:01 UTC 2004
On Thu, Mar 04, 2004 at 02:32:34PM +0100, Samuel Tardieu wrote:
> I couldn't find in the manual how darcs does when there is a merge
> conflict and no merge tool.
> Shouldn't darcs put the conflicting patches "on hold" and require a
> merger to be committed before going on?
> Also, couldn't it use 3 way merge markers in files containing both the
> original version, the first patched version and second patched
> version, as does arch with "star-merge -t"?
A "merger" patch is created whenever there is a conflict, but the
resolution of the merge has to be done by hand (or there wouldn't be a
In some obvious cases, darcs guesses how to resolve the conflict, and just
does that. This is when both changes are identical (it only does it once),
or if both changes add a line at the same location in a file (it chooses
which goes first alphabetically), or similar cases. These are still
conflicts, but usually all that is needed to resolve this sort of conflict
is a pull (which results in the conflict) followed by a whatsnew (to see
what darcs did with it) and a record.
In other cases, darcs puts conflict markers into the files, but they aren't
very good markers, as they don't indicate which version is which.
Fortunately, unless you have local changes to your files that you need to
preserve, you can always revert, unpull, and try again (possibly using a
Better merge handling would be very nice. That was in fact one of the
reasons for working on the graphical darcs interface, which got bogged down
due to window resizing problems, and the fact that I no longer have
wxhaskell installed anywhere...
More information about the darcs-users