On Sun, 06 Apr 1997 20:52:56 -0400,
Stan Ryckman <stanr(_at_)sunspot(_dot_)tiac(_dot_)net> wrote:
BTW, if any feeping creaturism is going to be suggested, what I'd *really*
like to do is control what goes into the log and how it gets formatted.
Maybe a LOGFORMAT variable? For a model, programs such as trn and the
Seconded.
Granted, you could, and I do, use something like this, in the
interim (not that I don't think you've figured it out yourself
already):
:0
* ^FROM_DAEMON
* ^\/From: .*
{
LOG="$MATCH
"
}
This was originally intended to capture the From: line on mailing list
mail into the log and I thought I'd cope with excluding bounce
messages etc. later -- but in fact I've come to appreciate having the
From: line from those, too, displayed in the log. (BTW, my .procmailrc
goes to some lengths to throw away "expected" bounce messages before I
do this additional logging, though.)
Note the leading space on the second line. This makes log entries
like this:
From: Stan Ryckman <stanr(_at_)SUNSPOT(_dot_)TIAC(_dot_)NET>
From owner-spam-l(_at_)PEACH(_dot_)EASE(_dot_)LSOFT(_dot_)COM Mon Apr 7
07:38:53 1997
Subject: Re: Did anybody get this? ALSO: -0600 (EST)
Folder: inbox/spam-l 3144
... which I think is more readable than having both From lines at the
same indentation level.
The problem with this is that if there is an error somewhere along
the way, often the error message will "eat" the line with the leading
space, and the From_ line of the message will again have no
indentation at all (which is even less intuitive than having both From
lines at the same level of indentation).
So yes, I'd appreciate a way to customize the logging function. I
think Stan's proposal is a good one.
/* era */
--
Defin-i-t-e-ly. Sep-a-r-a-te. Gram-m-a-r. <http://www.iki.fi/~era/>
* Enjoy receiving spam? Register at <http://www.iki.fi/~era/spam.html>