mailwatch script wanted
Guy Harris
guy at sun.uucp
Sun Jul 28 14:45:13 AEST 1985
> Here is an alternative to the above which does not require knowing the mail
> spool path and file names:
>
> if (mail -e) echo 'You have mail.'
This only works if you have the S3/S5 version of "mail". (Besides, they
should have added a flag which tells "mail" to *print* a message instead of
returning an exit status, or to return one of *three* exit statuses. That
way, you can distinguish "You have mail (because you leave stuff around in
your mailbox until you've responded to it)" from "You have mail (because
some mail arrived since the last time you looked at your mailbox).") >
Guy Harris
More information about the Comp.unix.wizards
mailing list