Mail notification customization help

Open discussion on or around SGI; software/hardware related posts should go in the appropriate subforum.
Forum rules
Any posts concerning pirated software or offering to buy/sell/trade commercial software are subject to removal.
User avatar
Axxe
Posts: 49
Joined: Fri Jan 31, 2003 11:18 am
Location: FL, USA

Mail notification customization help

Unread postby Axxe » Wed May 28, 2003 6:36 pm

I have been trying to change the standard notifcation
of "You have mail" when I run mail in a shell.
No success.
I would like to have each user have his/her personalized
mail notification when checking for mail. NOT EMAIL.
Something along the lines as "Hello, <user>! You have some new mail
in your mailbox." Or something like that.
How may I do this?
Thanks.

Axxe
Insert witty signature here.

User avatar
nekonoko
Site Admin
Site Admin
Posts: 8145
Joined: Thu Jan 23, 2003 1:31 am
Location: Pleasanton, California
Contact:

Re: Mail notification customization help

Unread postby nekonoko » Thu May 29, 2003 2:24 pm

The email notification comes from /etc/cshrc or /etc/profile depending on your shell. An example:

Code: Select all

#
# /etc/cshrc - Default settings for all csh users
#
# This is 'sourced' before $HOME/.cshrc, which in turn preceeds $HOME/.login
# when a csh user logs in or invokes /bin/su with the `-' option.

# Tell the shell where to look for mail.
if ($?MAIL == 0) setenv MAIL /usr/mail/$USER
set mail=$MAIL

if (! $?ENVONLY) then

        # Print the message of the day.
        cat -s /etc/motd

        # Check for mail.
        if ( -e /bin/mail ) then
            if ( { /bin/mail -e } ) then
                echo 'You have mail.'
            endif
        endif
endif

setenv MSGVERB text:action
setenv NOMSGLABEL 1
setenv NOMSGSEVERITY 1


You could either customize this directly, or put something similar in your user's ~/.cshrc or ~/.profile (once again depending on the shell used).

Hope this helps.
Twitter: @neko_no_ko
IRIX Release 4.0.5 IP12 Version 06151813 System V
Copyright 1987-1992 Silicon Graphics, Inc.
All Rights Reserved.

User avatar
Axxe
Posts: 49
Joined: Fri Jan 31, 2003 11:18 am
Location: FL, USA

Thank you

Unread postby Axxe » Thu May 29, 2003 3:19 pm

Excellent! Thank you!
I was looking in the wrong .cshrc file :cry:

Axxe
Insert witty signature here.


Return to “SGI: Discussion”

Who is online

Users browsing this forum: No registered users and 1 guest