----- Original Message -----
From: "Eric Lalonde" <[EMAIL PROTECTED]>
| It seems taht unless there is a symbolic link from /var/spool/mail/user to
| /home/user/Mailbox, the user will not be notified, if they are logged into
| the box, that they have new mail.
| Since I want users to be notified when new mail arrives, is there a way to
| streamline the process of creating symbolic links when new users are added
| to the box? Make it so whenever a new user is added to the box, a symbolic
| link from /var/spool/mail/user is also created?
|
| any ideas are appreciated.
|
| eric lalonde
Hmmm.. shell script front-end that does useradd tricks and -- somewhere in
the script -- does the symlink trick you need as well.
However....
If your users are using bash you can set the env var MAILPATH. From the
bash man:
MAILPATH
A colon-separated list of file names to be checked
for mail. The message to be printed when mail
arrives in a particular file may be specified by
separating the file name from the message with a
`?'. When used in the text of the message, $_
expands to the name of the current mailfile. Exam�
ple:
MAILPATH='/usr/spool/mail/bfox?"You have
mail":~/shell-mail?"$_ has mail!"'
Bash supplies a default value for this variable,
but the location of the user mail files that it
uses is system dependent (e.g.,
/usr/spool/mail/$USER).
For each user you can do something like:
export MAILPATH="${HOME}/Mailbox?New mail has arrvied in \$_"
You can also set the env var MAILCHECK to the number of seconds between mail
checks.
MAILCHECK
Specifies how often (in seconds) bash checks for
mail. The default is 60 seconds. When it is time
to check for mail, the shell does so before dis�
playing the primary prompt. If this variable is
unset, the shell disables mail checking.
Ciao,
kw
/*
** Keith Warno
** Make Us An Offer, Inc.
** Real-Time Online Haggling
** http://www.HaggleWare.com/
*/