procmail
[Top] [All Lists]

Re: Removing [somelist] from subject lines

2001-01-23 15:08:51
"Mike A. Harris" wrote:
:0c:
backups/backup-$(date +"%Y-%m-%d")

Will the above command substitution work?

I don't know if it will, but I wouldn't do it.  Instead I suggest
using something like this...

    :0c:
    backups/backup

so that you don't start a shell and run 'date' for every single
message.  Include something like this in your .procmailrc:

  :0
  * ^From: me
  * ^To: me
  * ^Subject: something nobody else will use
  * maybe some other condition to guarantee uniqueness
  {
    LOCKFILE=backups/backup.lock
    # Now nobody can write backup

    BF=backups/backup-%d

    :0 hciW
    | mv -f backups/backup $BF

    LOCKFILE
  }

and have a cron job to "mail -s something nobody else will use" etc.
once a day, say at 5:00 AM.

--
Neither I nor my employer will accept any liability for any problems
or consequential loss caused by relying on this information.  Sorry.
Collin Park                         Not a statement of my employer.
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail