Is there a shell script to send notifications on mail events?
Web mail isn't going to be a basic scripting topic, so since you're new you'll need to have a mail client set up.

Assuming that's the case, heres a script that checks for new mail by comparing dates of latest messages. It checks every 10min and will send a notification if there's new mail.


Open Script Editor
Copy and Paste the script
Go to File>Export
File Format = Application
Make sure Stay open after after script handler is checked
Open the application




tell application "Mail"
set new1 to date received of (first message of inbox)
repeat
    check for new mail
    delay 5 --wait until all new messages are in the box 
    set new2 to date received of (first message of inbox)
    if new2 is not equal to new1 then
        display notification "You've got Mail." with title "New Mail"
    end if

    ## For the AOL Effect ##

    # do shell script "say \"You've got mail\""
    set new1 to new2
    delay 600 -- 10 min in seconds 
end repeat
end tell