Subject: procmail vs. Elm's filter

From: [email-masked] (David W. Tamkin)
Date: Sat, 30 Jul 1994 14:42:58 -0500 (CDT)

Dean Martineau asked,

| this is the first of a few elementary questions.  I'm curious if people 
| have found advantages or disadvantages of procmail over the elm filter 
| program.  they appear to do about the same thing.

In addition to what Bill Jenuwine and Ranjan Bhattacharya have already men-
tioned, procmail can perform multiple actions on one incoming letter, but
with Elm's filter you have to resort to a lot of trickery to do that.  It can
check on conditions other than the text (and filter's ability to check text
is limited to certain header lines; it cannot understand any other header
lines and the only thing it can test in the body is how many lines are in the
total letter), make sure the environment is right, and, most importantly of
all, lock all folders.  filter will lock only the main mail spool and glee-
fully let text mix in other folders.

The only disadvantage to procmail is that its rcfile syntax is a little
harder to learn.  Otherwise there is no comparison: filter's capabilities
are a small subset of procmail's.

| I've read the man page, and want to be sure before I leap into letting 
| Procmail handle my mail.  Somebody told me that you use the .forward file 
| to pipe mail to Procmail.  Hence, should the .forward file begin with a 
| pipe symbol | or simply the necessary command?

To put a pipe into .forward, you need the pipe symbol and the quotation
marks.  If you name a file without a pipe symbol, sendmail will try to append
incoming mail to that file, so if you put just "/usr/local/bin/procmail"
into your .forward, sendmail will try to append your incoming mail to the
/usr/local/bin/procmail executable!  Since you as the recipient generally
won't have write permission on the binary, sendmail will just lose your mail.
If you do have write permission on the binary, appending mail to it may ruin
it, and it certainly won't put your incoming mail where you can see it.

| My final elementary question for the evening: can Procmail be used to 
| strip some of the useless mail header lines from messages?

The procmail distribution incluces a program called formail, which will
take care of that and can do a number of other things as well: see the 
man page for formail.

David W. Tamkin  P. O. Box 3284  Skokie IL  60076-6284
[email-masked]   MCI Mail: 426-1818   +1 312 714 5610