[comp.sys.sgi] Biff summary

loki@NAZGUL.PHYSICS.MCGILL.CA (Loki Jorgenson Rm421) (01/21/91)

	With regards to "biff" or biff-like mail alerting programs
for the IRIS, this is a short summary for those interested.

	Unfortunately, I wasn't specific enough and many people suggested
"xbiff" or "mailbox" (native to IRIX).  I should have said that I use a
VT100 ascii terminal most of the time and so the console-based programs
are inappropriate.  I prefer how the stars turn green in the "night" back-
ground program by choice.

	Others caught on and suggested various alternatives including some
of their own creations (see below).  One person even said that they had
biff working on their IRIS; I succeeded in compiling it but it didn't do
anything when I used it.  I finally have learned to live with just
receiving synchronous notification from the csh.
                             __          __
Loki Jorgenson              / /          \ \  node:  loki@Physics.McGill.CA
Grad, Systems Manager      / //////  \\\\\\ \ BITNET: PY29@MCGILLA
Physics, McGill University \ \\\\\\  ////// / fax:   (514) 398-8434
Montreal Quebec CANADA      \_\          /_/  phone: (514) 398-7027


Thanks to:
david@iris.claremont.edu  uunet!jarthur!iris!david
farestam@ultima.cerfacs.fr (Stefan Farestam)
crow!rpaul@ccut.cc.u-tokyo.ac.jp
leibowit@msdrl.com
smd@rehder.larc.nasa.gov

david@iris.claremont.edu  uunet!jarthur!iris!david
 When you are on the graphics console, you can use mailbox(1). ( This showed
 up only with 3.3 Irix.  [if running 3.3, also try 'apropos mail' { but of
 course you have to use makewhatis(1M) first to build a database of man
 page headers < see, that wasn't too hard, now was it! > } ] )

 Off the console, I use newmail(1) from the elm(1) system. Available for ftp
 at various sites.

farestam@ultima.cerfacs.fr (Stefan Farestam)
   I use the shellscript listed below to have my mail checked. It
   uses "at" to run itself continously with a one minute intervall
   (if 1 is given as argument). I don't like the fact that it consumes
   CPU regularly, and would rather prefer something that runs in the
   background. Consequently I would be interested if there turns out
   to be a version of biff available for the SGI.

-------------------------------------------------------------

#!/bin/csh -f

/bin/mail -e && ( \
   set term   = "/dev/"`who | grep $USER| awk 'NR ==1 {print $2}'` ;        \
   set sender = `cat /usr/mail/$USER | awk '{ if ($1 ~ /^.rom:/) {     \\
               if (($2 ~ /.*@.*/) || ($2 ~ /<.*>/))  se = $2  ; \\
               if (($3 ~ /.*@.*/) || ($3 ~ /<.*>/))  se = $3  ; \\
               if (($4 ~ /.*@.*/) || ($4 ~ /<.*>/))  se = $4  ; \\
               if (($5 ~ /.*@.*/) || ($5 ~ /<.*>/))  se = $5  ; \\
               if (($6 ~ /.*@.*/) || ($6 ~ /<.*>/))  se = $6  ; \\
               if (($7 ~ /.*@.*/) || ($7 ~ /<.*>/))  se = $7  ; \\
               if (($8 ~ /.*@.*/) || ($8 ~ /<.*>/))  se = $8  ; \\
               if (($9 ~ /.*@.*/) || ($9 ~ /<.*>/))  se = $9  ; \\
               if (se ~   /<.*>/)   se = substr(se, 2, length(se) - 2) ; \\
               if (se == "")  se = $2                         ; \\
               printf(" %s ", se)  ;} }'` ; \
   echo "\007" >$term ;\
   say -s30 -r -480,600  \
   "" "     You have mail     " "from" $sender "" )

if (`who | fgrep $USER | awk 'END {print NR}'` > 0) then
   echo "nice -19 $0 $1 1>/dev/null 2>&1" | at now + $1 minutes
endif

--

crow!rpaul@ccut.cc.u-tokyo.ac.jp
ccut.cc.u-tokyo.ac.jp!crow!rpaul
If you use 'csh', there's a variable you can change from the default time to
inform you of new mail. If you allways use a console, there's a graphical
program called 'mailbox'. Check the manuals.

leibowit@msdrl.com
We have biff running on sgi's on site.

smd@rehder.larc.nasa.gov
I wrote my own that works on regular old terminals, using termcap.  It puts a
message telling you who the new mail (as well as any unread messages) is
from in the lower right hand corner of your screen... in highlighted text
if your terminal can do it.  You start it up in your .login and it
kills itself when you log out.  Written in bourne shell and C.  Not
the most elegant approach, but it does work.

                             __          __
Loki Jorgenson              / /          \ \  node:  loki@Physics.McGill.CA
Grad, Systems Manager      / //////  \\\\\\ \ BITNET: PY29@MCGILLA
Physics, McGill University \ \\\\\\  ////// / fax:   (514) 398-8434
Montreal Quebec CANADA      \_\          /_/  phone: (514) 398-7027