[PATCH RFC] util: set $HG var correctly for shell aliases (issue2867)

Idan Kamara idankk86 at gmail.com
Wed Jun 29 11:25:54 CDT 2011


On Wed, Jun 29, 2011 at 6:08 PM, Mads Kiilerich <mads at kiilerich.com> wrote:

> On 06/29/2011 04:42 PM, Idan Kamara wrote:
>
>> # HG changeset patch
>> # User Idan Kamara<idankk86 at gmail.com>
>> # Date 1309358034 -10800
>> # Branch stable
>> # Node ID c64c8a0911544a924df2419882c39d**447a2b630b
>> # Parent  6ac6a32ac1605176befb7c4fdbe90b**a952c59207
>> util: set $HG var correctly for shell aliases (issue2867)
>>
>> The old version took the first 'hg' it found in $PATH, or simply the
>> basename
>> of sys.argv[0]. This is a problem if the 'hg' being used is not the first
>> in
>> $PATH. Also the use of basename on sys.argv[0] is inappropriate, because
>> that
>> effectively strips it to 'hg'.
>>
>> Instead we're always setting it to sys.argv[0].
>>
>
> Does that mean that the analysis in http://mercurial.selenic.com/**
> bts/issue644 <http://mercurial.selenic.com/bts/issue644> was wrong?
>

Seeing that sooner might have helped my understanding of what's going on
there.

Not sure if this is good then, needs testing on Windows for sure.
Since this is not such a major issue, might as well do this another time,
not 1 day before the release.


>
> /Mads
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20110629/50b00ff7/attachment.htm>


More information about the Mercurial-devel mailing list