[Mailman-Users] scripts/answer_majordomo_mail

Pioppo pioppo at ferrara.linux.it
Thu Dec 2 21:34:00 CET 1999

Il Thu, 02 Dec 1999, Paul Tomblin ha scritto:

> > I tried to setup the $prefix/scripts/answer_majordomo_mail 
> > tool but with no success. 

> I couldn't get it to work either, so I replaced it with:
> #!/bin/sh
> (formail -rt; cat /usr/home/mailman/misc/majordomo.answer.txt) | /usr/lib/sendmail -oi -t

Very good!
Following your example:

FROM="mailman at ferrara.linux.it"
TMPFILE=`mktemp /tmp/$0.XXXXXX`
if [ $? -ne 0 ]; then
   echo "$0: Can't create temp file, exiting..."
   exit 1
cat > $TMPFILE
   echo "From: $FROM"
   cat $TMPFILE | formail -rt
   echo "Hi."
   echo "This is an autogenerated reply to your message."
   echo "We non longer run majordomo here - we use Mailman."
   echo "To subscribe to our lists please visit:"
   echo "http://ferrara.linux.it/mailman/listinfo"
   echo "Your original request follows." 
   cat $TMPFILE | formail -k -X From: -X Subject: -X Date: \
      -X To: | awk '{print "> "$0}' 
)|/usr/sbin/sendmail -t
rm -f $TMPFILE

    Simone Piunno,  http://pioppo.cjb.net,  simone at piunno.com
     Ferrara Linux Users Group  -->  http://ferrara.linux.it
      ICQ UIN: 6914669 pioppo at IRCnet on #ferrara, #linux-it 
GnuPG/PGP5 fp: 9C15 F0D3 E309 3593 AC95  2C92 A0CD 52B4 8603 14FC

More information about the Mailman-Users mailing list