zsh-users
 help / color / mirror / code / Atom feed
* showing 'talk' status in PROMPT
@ 1997-10-27  4:43 Timothy J Luoma
  1997-10-27  8:52 ` Peter Stephenson
  1997-10-28  1:28 ` Deborah Ariel Pickett
  0 siblings, 2 replies; 6+ messages in thread
From: Timothy J Luoma @ 1997-10-27  4:43 UTC (permalink / raw)
  To: zsh-users


I am using this to let me know if I have turned off messages on my terminal:

mesg () {

        case $1 in
                n*|off)
                        TALK="<notalk> "
                        /usr/bin/mesg n
                ;;

                *)
                        /usr/bin/mesg $*
                        TALK=""

                ;;
        esac
}




# note: the next line is all one line until the %b
# then another line break after the %s
PROMPT='%SUSER: %B(%n)%b HOST: %B(%M)%b TTY: %B(tty%l)%b HIST#: %B(%h)%b
[OLDPWD: %B$OLDPWD%b] [PWD: %B%~%b]%s
$TALK'

Does anyone see any problems with this, or have a better way to do this?

Thanks

TjL


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~1997-10-28  1:36 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-10-27  4:43 showing 'talk' status in PROMPT Timothy J Luoma
1997-10-27  8:52 ` Peter Stephenson
1997-10-27 17:18   ` Timothy J Luoma
1997-10-27 17:21   ` Bart Schaefer
1997-10-27 18:13     ` Andrew Main
1997-10-28  1:28 ` Deborah Ariel Pickett

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).