[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: BASH_ENV does not behave as expected.
From: |
Paul Jarc |
Subject: |
Re: BASH_ENV does not behave as expected. |
Date: |
Mon, 28 Jan 2002 11:35:00 -0500 |
User-agent: |
Gnus/5.090006 (Oort Gnus v0.06) Emacs/20.7 (i386-redhat-linux-gnu) |
Eric Darrot <tech@keynux.com> wrote:
> Well, easy description, the following doesn't work:
>
> echo "echo hello-world" > /tmp/bashenv.sh
> chmod 755 /tmp/bashenv
> BASH_ENV=/tmp/bashenv.sh bash
That behavior is correct.
> But it should, as stated in the man page:
You missed the beginning of that paragraph:
When bash is started non-interactively, to run a shell
script, for example, it looks for the variable BASH_ENV in
the environment, expands its value if it appears there,
and uses the expanded value as the name of a file to read
and execute.
You're starting bash interactively, so $BASH_ENV is not used.
paul