Re: shell script question - changing PS1 based on tty
On 29 May 2007 20:15:45 -0700, mowgli
<knowledgeless@gmail.com> wrote:
>
>
> I just made a simple shell script for changing the color username in
> the PS1 prompt. The same commands if given one by one on the command
> line, change the prompt as per the commands, all fine. But if the
> script is executed, the prompt does not change. However the echo
> statement is echoed fine and echo $? returns true.
>
Your script changes PS1, but that change is only in effect until the
script ends, unless you source the script.
--
The cost of living has just gone up another dollar a quart.
-- W. C. Fields
|