[Gllug] Changing the text colour at the command line
Laurie Turpin
laurie.turpin at virgin.net
Sun Dec 8 16:50:48 UTC 2002
----- Original Message -----
From: "Stig Brautaset" <stigbrau at start.no>
To: <gllug at linux.co.uk>
Sent: Sunday, December 08, 2002 4:27 PM
Subject: Re: [Gllug] Changing the text colour at the command line
> On Dec 08 2002, Laurie wrote:
> > Hi
> >
> > I have playing around with my PS1 and PS2 enviroment variables.
> > I have created a more interesting command line prompt, which is
> > different for users and root It also means that when I enter commands
> > at the command line the commands are in red when it is root and green
> > when i'm a user
> > I'm quite happy about that and think it looks cool What I have a
> > problem with is that when I logout The login prompt is in the colour
> > of the last person i.e green text if the last person was a user red
> > text if the last person was root
> > I want the logging prompt to go back to being white and only change
> > colour when I login Is there a text enviroment variable?
> > also is there anything like a "unprofile" script which runs when you
> > logout?
> > I was thinking I could make a script change the variable when I logout
> > or shutdown?
>
> try to put this in your ~/.bash_logout:
>
> PS1=""
> PS2=""
> export PS1 PS2
>
>
Thankyou for your reply
I tried what you suggest and it does not work.
If at the command line I type PS1="\[\033[0; 36m\]"
the text returns to white
I can then logout to a white login prompt
but I want it to be automatic so I just type logout and the text goes from
coloured to a white login prompt
--
Gllug mailing list - Gllug at linux.co.uk
http://list.ftech.net/mailman/listinfo/gllug
More information about the GLLUG
mailing list