sorry i was at work so i didnt have it
Here is how to make mutt send email using ur gmail account
1) Logon to ur gmail account , in settings -> Forwarding and POP
enable pop for all mail
2) Download nbSMTP (nbSMTP is a simple SMTP)
NOTE : u have to have openssl , libssl-dev installed
3) setup mutt by making a file named .muttrc in my HOME
here is mine :
folder-hook . "my_hdr From: <email@example.com>"
set sendmail="/usr/local/bin/nbsmtp -U username -P password -d gmail.com -h smtp.gmail.com -f firstname.lastname@example.org
-p 587 -M p -S"
NOTE : ofcourse u have to enter ur username and password
Finally test it out by typing :
echo "It Works" | mutt -s "It Finally works" email@example.com
as for recieving here is a site i have found :
and here is my script :
# Apollon check script
# To use it type : ./check.sh filename
FILENAME2=$(ls | grep "$1")
echo -e "\033[0;31mRunning script now\033[0m"
while true; do
if [ -f "$FILENAME3" ]; then
echo "File $FILENAME3 downloaded" | mutt -s "File Downloaded" firstname.lastname@example.org
elif [ -f "$FILENAME" ]; then
echo "File $FILENAME is still being downloaded"
echo "File not found"
sleep 300 # sleeps for 5 minutes then checks again