procmail
[Top] [All Lists]

variable expansion for logging of delivery?

2010-08-19 13:21:42

If I use:

MBNAME=somefile

:0:
|gzip -9fc >> ${MBNAME}.gz

then the log shows:

From **redacted**  Thu Aug 19 11:06:46 2010
 Subject: Blah blah
  Folder: gzip -9fc >> ${MBNAME}.gz                                  2085

The message itself IS delivered to the correctly named
(expanded) file.  Same thing occurs whether the variable is enapsulated in
braces or not.

How can I get the logging to reflect the actual name?


Not really pertinent to the technical issue above, but the actual use of
the expanded variable isn't nearly as simple as used in the example given
- I'm restructuring things so that more of my filing is done via an
included recipe that deals with the mechanics of it.  Thus, individual
recipes migh match their conditions, and then:

{
        MBNAME=base_name_of_mailbox
        MBTAG=text_to_tag_into_header
        INCLUDERC=filer.rc
}

MBTAG is inserted into the headers of the copy delivered to the inbox,
while a compressed archive is made to $MBNAME.gz.  Additional things may
occur with the message if other specific variables are set.  This sharply
reduces some repetative junk in my rather extensive rcfile collection, and
also allows me to uniformly add redirection and other features, which can 
be controlled by setting other variables before inclusion.

____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)de
http://mailman.rwth-aachen.de/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>
  • variable expansion for logging of delivery?, Sean Straw <=