procmail
[Top] [All Lists]

Re: using LOG= in recipes, newline character and mailstat

2006-01-19 03:49:25
He Stephan,

I am using for example:

  __( '/home/michelle.konzack/.procmailrc' )____________________________
 /
| PATH=$HOME/bin:/usr/bin:/bin:
| MAILDIR=$HOME/Maildir
| DEFAULT=$MAILDIR/.ATTENTION/
| TDPID=$$
| ORGMAIL=
| 
| SP="  "
| NL="
| "
| 
| #-------------------------------------------------------------------
| VERBOSE=off
| LOGFILE=$HOME/log/procmail/`date +%Y-%m-%d`.log
| #-------------------------------------------------------------------
| 
| LINEBUF=65536
| 
| LOG="################ NEW MESSAGE AT `date '+%Y-%m-%d %H:%M:%S'` 
################$NL"
<snip>

which put at the beginning of a new Message entering procmail
a Date line.

| INCLUDERC=$HOME/.procmail/FLT_blacklist
<snip>

and then something like

  __( '/home/michelle.konzack/.procmail/FLT_blacklist' )________________
 /
| :0
| * ? test ! -f "`which tdmailblacklist`"
| { 
|   LOG="($TDPID) FLT_blacklist     : executable "tdmailblacklist" not 
found.$NL"
| }
| 
| :0
| * ? test -f "`which tdmailblacklist`"
| { 
|   LOG="($TDPID) FLT_blacklist     : pass$NL"
| 
|   :0 fw
|   |tdmailblacklist --filter blacklist
| 
|   :0
|   * ^Subject:.*(***BLACKLIST***)
|   .ATTENTION.FLT_blacklist/
| }
 \______________________________________________________________________

Please note the $NL at the end of the LOG entries

Which give me a Logfile of:

  __( '/home/michelle.konzack/log/procmail/2006-01-18.log' )____________
 /
| ################ NEW MESSAGE AT 2006-01-18 07:27:49 ################
| (14111) FLT_dos_coded     : pass
| (14111) FLT_schrott       : pass
| (14111) FLT_cced          : pass
| (14111) NET_sysmessages   : pass
| (14111) NET_pingbot       : pass
| (14111) NET_tdautobuilder : pass
| (14111) NET_ml4michelle   : pass
| (14111) TDmailcopy        : pass
| (14111) FLT_received      : pass (1)
| (14111) My_Progs          : pass
| (14111) FLT_yavr          : pass
| (14111) FLT_virus_aav     : pass
| (14111) FLT_virus_aav_old2: pass
| (14111) FLT_virus_aav_old : pass
| (14111) FLT_virus         : pass
| (14111) F-Prot            : executable "fprot" not found.
| (14111) FLT_blacklist     : pass
| From MAILER-DAEMON(_at_)hausmasta(_dot_)austria(_dot_)eu(_dot_)net Fri Jan 13 
11:33:12 2006
|  Subject: ***BLACKLIST***  Status
|   Folder: .ATTENTION.FLT_blacklist/new/1137565671.14111_0.samba3.priva        
  40872
 \______________________________________________________________________


Greetings
    Michelle Konzack
    Systemadministrator
    Tamay Dogan Network
    Debian GNU/Linux Consultant


-- 
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack   Apt. 917                  ICQ #328449886
                   50, rue de Soultz         MSM LinuxMichi
0033/3/88452356    67100 Strasbourg/France   IRC #Debian (irc.icq.com)

____________________________________________________________
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