[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fwd: BASH_ARGV0 do not inherit from environment variables
From: |
Chet Ramey |
Subject: |
Re: Fwd: BASH_ARGV0 do not inherit from environment variables |
Date: |
Tue, 8 Jan 2019 11:39:56 -0500 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:60.0) Gecko/20100101 Thunderbird/60.4.0 |
On 1/8/19 1:47 AM, Cuong Manh Le wrote:
> Hi,
>
> I'm not sure this a feature or bug, but:
>
> $ BASH_ARGV0=foo /usr/local/stow/bash/bin/bash -c 'echo "$0"'
> /usr/local/stow/bash/bin/bash
>
> I expect $0 set to foo instead.
Thanks for the suggestion. BASH_ARGV0 comes in as a feature suggested
by the bash debugger, so it's what the debugger can use to replace
the `set0' loadable builtin it includes.
I'll keep this in mind for a future version.
Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/