version 1.2, 1996/12/16 03:49:50 |
version 1.3, 1998/03/22 03:39:10 |
|
|
# install whoami.sh |
# install whoami.sh |
USER=`whoami 2>/dev/null` |
USER=`whoami 2>/dev/null` |
USER=${USER:-`id | sed 's/^[^(]*(\([^)]*\)).*/\1/'`} |
USER=${USER:-`id | sed 's/^[^(]*(\([^)]*\)).*/\1/'`} |
|
UID=`id -u` |
case $UID in |
case $UID in |
0) PS1S='# ';; |
0) PS1S='# ';; |
esac |
esac |
|
|
tty=`tty` |
tty=`tty` |
tty=`basename $tty` |
tty=`basename $tty` |
TTY=${TTY:-$tty} |
TTY=${TTY:-$tty} |
# console is the system console device |
|
console=`sysctl machdep.console_device | cut -d' ' -f3` |
|
|
|
set -o emacs |
set -o emacs |
|
|
|
|
;; |
;; |
esac |
esac |
case "$TERM" in |
case "$TERM" in |
sun*) |
sun*-s) |
# these are not as neat as their csh equivalents |
# sun console with status line |
if [ "$tty" != "$console" ]; then |
if [ "$tty" != "$console" ]; then |
# ilabel |
# ilabel |
ILS='\033]L'; ILE='\033\\' |
ILS='\033]L'; ILE='\033\\' |