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

Re: [MiNT] Strange FreeMiNT behavior



Hi!

On Wed, Nov 21, 2001 at 07:00:40PM +0000, Adam Klobukowski wrote:
> 2) Similar thing like 1) - my bash prompt looks like:
> 
> root@falcon/$
> 
> Even if I'm logged as ROOT!
> 
> My PS1 varible looks like this: PS1="\u@\H\w\$"

Then bash's behaviour is perfectly OK. Remember that $ is a special
character even inside double quotes, thus \$ will simply escape the $
before the assignment is made, and PS1 is actually set to \u@\H\w$. When
using backslashes in variable assignments, it's best to use single
quotes around the value, ensuring they all pass literally:

PS1='\u@\H\w\$'


Ciao

Thomas


-- 
Thomas Binder (Gryf @ IRCNet)
gryf@hrzpub.tu-darmstadt.de
PGP-key available on request!