[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Should this be this way?

From: Linda Walsh
Subject: Re: Should this be this way?
Date: Mon, 25 Feb 2013 21:41:14 -0800
User-agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv: Gecko/20100228 Lightning/0.9 Thunderbird/ Mnenhy/

Chris Down wrote:
> On 2013-02-25 18:27, Linda Walsh wrote:
>> I mentioned that everything in my ENV and usage pointed at /bin/bash.
> You gave $SHELL, which is not really relevant (it doesn't necessarily 
> reference
> your login shell, or your current shell either).
        I also gave my login shell and that bash was in my current
path, I thought that the default in executing a shell script
was to use my login or $SHELL value .. that both of them were the
same was my point.

>> Why would I do that, and then use 'sh script'?
>> Wouldn't that sorta be deliberately misleading?
> You'd be surprised what people do without thinking about it. Seems like a
> well-intentioned question to me, at least.

> Either way, the code you're looking for is in `shell_execve' in 
> `execute_cmd.c',
> it should explain the behaviour that you're seeing. It's very well commented,
> you should be able to find your answer there.

        It isn't using the current value of SHELL as my shell nor the value
of my login shell.

        It is forcing interpretation into /bin/sh, which I don't use.

        This brings me back to the original question...
"Should this be this way?"

        I think it is a bit odd to have my default shell behavior NOT be
what is in my login nor in my SHELL variable - I found it confusing to have
some "alien" shell semantics applied to my shell and couldn't figure out how
it got what it got...

        Um... RFE?

        Maybe execute the program under whatever shell they are currently 
running as?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]