On Saturday 25 Oct 2003 14:33, Dennis Robertson wrote:
> Hello Barry,
> Following your advice I get:  dencar (~) $  at the prompt. The aterm
> titlebar reads: [EMAIL PROTECTED]:~ which is correct. Can you help
> further with the prompt to have it specify user dennis, please. TIA.
> BTW there is a script in ~/.bashrc to change the window title of X
> terminals, which I assume is producing the titlebar entry I
> mentioned.
>
In /etc/profile:
if [ `/usr/bin/whoami` = 'root' ]
then
  # Do not set PS1 for dumb terminals
  if [ "$TERM" != 'dumb'  ] && [ -n "$BASH" ]
  then
    export PS1='\[\033[01;31m\][$(/bin/date +%H:%M) [EMAIL PROTECTED] \[\033[01;34m
\]\w\[\033[01;31m\]]\n\$ \[\033[00m\]'
  fi
else
  # Do not set PS1 for dumb terminals
  if [ "$TERM" != 'dumb'  ] && [ -n "$BASH" ]
  then
    export PS1='\[\033[01;32m\][$(/bin/date +%H:%M) [EMAIL PROTECTED] \[\033[01;34m
\]\w\[\033[01;32m\]]\n\$ \[\033[00m\]'
  fi
fi

Peter
-- 
======================================================================
Portage 2.0.49-r15 (default-x86-1.4, gcc-3.2.3, glibc-2.3.2-r1, 
2.4.23_pre7-gss)
i686 AMD Athlon(tm) XP 3200+
======================================================================


--
[EMAIL PROTECTED] mailing list

Reply via email to