[PATCH 3 of 5] merge: add a tool to emulate old hgmerge's fallback $EDITOR mode
Steve Borho
steve at borho.org
Mon May 10 12:39:46 CDT 2010
On Mon, May 10, 2010 at 12:10 PM, Steve Borho <steve at borho.org> wrote:
> On Mon, May 10, 2010 at 11:48 AM, David Champion <dgc at uchicago.edu> wrote:
>> # HG changeset patch
>> # User David Champion <dgc at uchicago.edu>
>> # Date 1271869686 18000
>> # Node ID 0b61e87b1e3f0f45b45e2be0a6b32aa4a8aa0c7f
>> # Parent 487c5dc6de123af55c864b339cecdeab8ba22b31
>> merge: add a tool to emulate old hgmerge's fallback $EDITOR mode
>>
>> Uses premerge=keep to force markers to be left in
>> $local so that sh -c ${VISUAL:-${EDITOR:-vi}} can tackle them. This
>> permits a synchronous 3-way editor merge as a fallback within the
>> merge-tools framework without requiring a shell script and the "merge"
>> program from RCS (which is redundant to internal:merge anyway).
>>
>> diff -r 487c5dc6de12 -r 0b61e87b1e3f contrib/mergetools.hgrc
>> --- a/contrib/mergetools.hgrc Wed Apr 21 12:02:51 2010 -0500
>> +++ b/contrib/mergetools.hgrc Wed Apr 21 12:08:06 2010 -0500
>> @@ -84,3 +84,11 @@
>> araxis.checkconflict=True
>> araxis.binary=True
>> araxis.gui=True
>> +
>> +editor.executable = /bin/sh
>> +editor.args = -c "${VISUAL:-${EDITOR:-vi}} $local"
>> +editor.premerge = keep
>> +editor.checkconflicts = True
>> +editor.checkchanged = True
>> +editor.priority = -99
>> +editor.gui = False
>
> To avoid leaving our Windows users out in the cold, and for simple
> completeness, we should provide a way to tell the merge-tool machinery
> to use the configured ui.editor with this tool configuration.
Something to the effect of:
editor.executable = `ui.geteditor()`
editor.args = $local
Only cleaner.
--
Steve Borho
More information about the Mercurial-devel
mailing list