On Mon, 26 Jan 1998 15:06:22 -0800 (PST), david hunt <dh(_at_)west(_dot_)net>
wrote:
# Forward mail to list if from a member.
# Make sure the mail is explicitly to the List's address, to avoid junk.
# Use Cond.1 to make the list "closed".
# Use Cond.2 to avoid mail not addressed to list.
# You must use Cond.3. to avoid mailloops.
:0
* FROM ?? ? fgrep -isf "$FILE_O_ADDRESSES"
* ^(To|Cc):(.*\<)?(list's address)\>
* ! ^X-Loop:(.*\<)?(list's address)\>
| formail -I"Reply-To: whatever" \
-A"X-Loop: list's address" \
-I"Precedence: bulk" \
| $SENDMAIL -oielm `cat $FILE_O_ADDRESSES`
# ( I think I just got another "abuse of cat" award.)
(No, this is a valid use of cat. I usually advocate using a slightly
more costly operation, though, which improves user-friendliness by
allowing comments in the address file:
...| $SENDMAIL $SENDMAILFLAGS `egrep -v '^#' $FILE_O_ADDRESSES`
You should also probably force fgrep to accept only complete matches,
as in fgrep -ixsf [if your fgrep understands that].
... what does -elm mean to Sendmail? The version I have here doesn't
have -el, only -em, or do I misunderstand?)
/* era */
--
Paparazzi of the Net: No matter what you do to protect your privacy,
they'll hunt you down and spam you. <http://www.iki.fi/~era/spam/>