#11120: Autodetect installed 3-way merge programs (invalidates #4434)
------------------------+---------------------------------------------------
Reporter: kini | Owner: tbd
Type: defect | Status: needs_work
Priority: major | Milestone: sage-4.7
Component: packages | Keywords: mercurial, os x
Author: | Upstream: N/A
Reviewer: | Merged:
Work_issues: |
------------------------+---------------------------------------------------
Old description:
> In Mercurial versions earlier than 1.0, a script called `hgmerge` was
> installed to the system when you installed mercurial. This script called
> whatever 3-way merge programs you had installed in order to manually
> intervene in Mercurial's merging process when it couldn't figure out how
> to resolve a conflict.
>
> This was deprecated in version 1.0, and now Mercurial calls 3-way merge
> programs directly instead of relying on an `hgmerge` script. In order to
> make this work properly, one should set the proper configuration
> variables to help Mercurial find any installed 3-way merge programs.
>
> There is a file, `contrib/mergetools.rc`, in the Mercurial source
> distribution which provides exactly these configuration variables, though
> the upstream installer script does not actually install it anywhere.
>
> The problem reported at trac #4434 was caused, I guess, by the fact that
> `hgmerge` was deprecated and we sage people didn't notice, so the patch
> there simply caused our distribution of Mercurial to continue using
> `hgmerge`. The patch also did this only on the OS X platform, though as
> far as I can tell the same fundamental problem actually appears on Linux
> as well (see comments below).
>
> A better way to fix the problem on trac #4434, and fix it for Linux too,
> would be to use the `contrib/mergetools.rc` file as it was designed to be
> used.
>
> Apply trac_11120-re-fix-trac_4434.mercurial-spkg.patch to mercurial spkg
> base repository
>
> Depends on #11121
New description:
Depends on #11121 ; Apply trac_11120-re-fix-trac_4434.mercurial-spkg.patch
to mercurial spkg base repository
----
In Mercurial versions earlier than 1.0, a script called `hgmerge` was
installed to the system when you installed mercurial. This script called
whatever 3-way merge programs you had installed in order to manually
intervene in Mercurial's merging process when it couldn't figure out how
to resolve a conflict.
This was deprecated in version 1.0, and now Mercurial calls 3-way merge
programs directly instead of relying on an `hgmerge` script. In order to
make this work properly, one should set the proper configuration variables
to help Mercurial find any installed 3-way merge programs.
There is a file, `contrib/mergetools.rc`, in the Mercurial source
distribution which provides exactly these configuration variables, though
the upstream installer script does not actually install it anywhere.
The problem reported at trac #4434 was caused, I guess, by the fact that
`hgmerge` was deprecated and we sage people didn't notice, so the patch
there simply caused our distribution of Mercurial to continue using
`hgmerge`. The patch also did this only on the OS X platform, though as
far as I can tell the same fundamental problem actually appears on Linux
as well (see comments below).
A better way to fix the problem on trac #4434, and fix it for Linux too,
would be to use the `contrib/mergetools.rc` file as it was designed to be
used.
--
Comment(by kini):
Yes, you're right, it depends on #11121 (specifically on the patch there
which applies to the mercurial spkg). Sorry, I'll make that more prominent
in the ticket description. As for the error actually copying the file,
it's actually because the filename is wrong. It still needs to be called
`mergetools.rc` (or at least something`.rc`) in order to work, but in the
vanilla Mercurial source distribution it is actually called
`contrib/mergetools.hgrc` for some reason. It needs to be renamed during
the copy over. I think I had renamed it in my sandbox by mistake at some
point when trying to fiddle with it to test different diff viewers -
stupid oversight on my part. I'll fix it. Sorry for the inconvenience.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11120#comment:7>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.