procmail
[Top] [All Lists]

Executing commands: Am I doing this the hard (or wrong) way?

1995-10-05 19:48:10
I've been using procmail for a few months with wonderful success but I 
know I've only touched the surface and have a lot more to learn.  With 
the help of you on the list, I hope to learn more.

My question:  I have a cron job on my ISP's system that sends 4 gophermail
inquiries each day to a weather gopher.  My trivial procmail recipe 
captures the gophermail returns and remails them so they wind up 
in a UUCP spool feeding a computer I hook up to a ham radio.

Anway the server returns a busy message sometimes, which gets mailed to me
and overwrites the weather information.  Really Bad because the server 
was completely maxed out during the last hurricane.  

I just added a new recipe ahead of the old one that looks for the busy
message and re-queues the gophermail.  It works, but it seems a little
klugey with the cat > /dev/null.  Can anyone suggest a cleaner
alternative?  I use the pipe because I'm not sure how to execute a program
from a recipe that is not driven from a pipe (or a better way to dispose
of stuff sent from the pipe).  Here it is: 

---------------------------------

# process returning weather queries, check for busy response, requeue reqst
:0 D
* ^Subject:.*Zone Fcst
* B ?? Sorry
| (cat > /dev/null ; /usr/bin/mail -s gophermail hgoldste \ < 
      /home/hgoldste/wxfcst)
#

---------------------------------

Thanks

-- 
Howard Goldstein        <hg(_at_)n2wx(_dot_)ampr(_dot_)org>      
http://www.tapr.org/~n2wx/

<Prev in Thread] Current Thread [Next in Thread>
  • Executing commands: Am I doing this the hard (or wrong) way?, Howard Goldstein <=