In the below .procmailrc file, if I send a message with the subject of
"command get ascii me" procmail does the following:
1) puts a copy of the message in the backup mh folder
2) appends the header to .procmail/who.gz
[I've tried this rule without the 'c' as well, but it didn't make a
difference]
3) fails to match anything else in the block
4) puts the BODY of the message in the inbox mh folder
What is happening to the header of the message? I assume that it's not
matching any other rules in the block because the header is already
missing... Any help would be greatly appreciated...
Please reply directly to me as I'm not on the mailing list. Thanks in
advance...
MAILDIR=$HOME/Mail
DEFAULT=$MAILDIR/inbox/.
LOGFILE=$HOME/.procmail/log
SHELL=/bin/sh
TDIR=$HOME/tdir
:0 c
backup/.
:0
* !^Subject:.*Re:
* ^Subject: *command
{
MAILDIR=$TDIR
:0 hfwc
| /usr/contrib/bin/gzip >> $HOME/.procmail/who.gz
:0
* ^Subject: *command *get *bin *\/.*
{
FILE="$MATCH"
:0 hfw
| formail -rA "X-Loop: wilcoxon"
:0 afw
| rm -f tmp.uue; uuencode $FILE $FILE tmp.uue
:0 ah
| cat - tmp.uue | $SENDMAIL -oi -t
}
:0 E
* ^Subject: *command *get *ascii *\/.*
{
FILE="$MATCH"
:0 hfw
| formail -rA "X-Loop: wilcoxon"
:0 ah
| cat - $FILE | $SENDMAIL -oi -t
}
:0 E
* ^Subject: *command *ftp *\/.*
{
WHERE="$MATCH"
:0 hfw
| formail -rA "X-Loop: wilcoxon"
:0 abfw
| ncftp $MATCH 2>&1 | cat - > tmp.ftp
:0 ah
| cat tmp.ftp | $SENDMAIL -oi -t
}
:0 E
* ^Subject: *command *www *\/.*
{
WHERE="$MATCH"
:0 hfw
| formail -rA "X-Loop: wilcoxon"
:0 abfw
| rm -f tmp.www; www $MATCH 2>&1 | cat - > tmp.www
:0 ah
| cat tmp.www | $SENDMAIL -oi -t
}
MAILDIR=$HOME/Mail
}
:0
$DEFAULT