#! /bin/tcsh cd /disk/www/html/massive_stars/submission/ set date_add = `date +%y%m%d%H%M%S` if (-f "noti_emailmsg.txt" || -f "../jobs/noti_emailmsg.txt" || -f "../conf/noti_emailmsg.txt" || -f "../other/noti_emailmsg.txt") then echo "To: web.wgms@googlemail.com" >ready.mail echo "Bcc: `cat emailto`" >>ready.mail echo "From: Massive.Stars.Newsletter" >> ready.mail echo "Subject: New Massive Star Newsletter Abstracts in the Past 24 Hours" >> ready.mail echo "Content-type: text/plain">> ready.mail echo " " >> ready.mail if (-f "noti_emailmsg.txt") then echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" >> ready.mail echo "Abstracts" >> ready.mail echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" >> ready.mail cat noti_emailmsg.txt >> ready.mail mv noti_emailmsg.txt ../sent_noti/abs_noti""$date_add endif if ( -f "../jobs/noti_emailmsg.txt") then echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" >> ready.mail echo "Job Offers" >> ready.mail echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" >> ready.mail cat ../jobs/noti_emailmsg.txt >> ready.mail mv ../jobs/noti_emailmsg.txt ../sent_noti/job_noti""$date_add endif if ( -f "../conf/noti_emailmsg.txt") then echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" >> ready.mail echo "Conference Announcements" >> ready.mail echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" >> ready.mail cat ../conf/noti_emailmsg.txt >> ready.mail mv ../conf/noti_emailmsg.txt ../sent_noti/conf_noti""$date_add endif if ( -f "../other/noti_emailmsg.txt") then echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" >> ready.mail echo "Announcements" >> ready.mail echo "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" >> ready.mail cat ../other/noti_emailmsg.txt >> ready.mail mv ../other/noti_emailmsg.txt ../sent_noti/oth_noti""$date_add endif echo " " >> ready.mail echo "Visit the Online Archive http://www.astroscu.unam.mx/massive_stars for a complete list of all abstracts">> ready.mail /usr/lib/sendmail -t -v < ready.mail > mail.result mv ready.mail old.mail mv mail.result old.result endif