On Thu, Jun 22, 2000 at 06:16:07AM -0400, David T-G wrote:

> % Sorry if this isn't the right place to post this but I'm sure I got
> % this little code snippet from a mutt-related website...
> % 
> % I've got this in my .procmailrc file:
> % 
> % ## Nuke duplicate messages
> ...
> % ## Create backup cache of 100 most recent messages
> 
> First, you probably ought to back up your mail before discarding the
> duplicates, so reverse these two.

Yeah, that was pointed out so I've already done that.  =)

> % But it doesn't seem to be working properly (the backup part).  I've
> % got something like over 1000 messages in there now but I only want to
> % save the last 100.  Can someone tell me what I'm doing wrong?
> 
> How very interesting.
> 
> Here's how mine is set up:
> 
>   .procmailrc
>     MAILDIR=$HOME/Mail
>     PMDIR=$HOME/.procmail
>     FORMAIL=/usr/bin/formail
>     ...
>     INCLUDERC=$PMDIR/rc.backup
>     ...
> 
>   rc.backup
>     :0 c
>     00Backup/.
> 
>     :0 ic
>     | cd 00Backup && rm -f dummy `ls -t | sed -e 1,500d`
> 
>     :0 Wh: msgid.lock
>     | $FORMAIL -D 8192 $HOME/.procmail/msgid.cache
> 
> This drops a sequentially-numbered clone of the email in $MAILDIR/00Backup,
> uses the clone function to run the backup script (cd to 00Backup and then
> remove messages that are left after removing the 500 most recent), and
> *then* pumps it through formail against my Message-ID: cache file.
> 
> Note the trailing /. on the first recipe, where the copy gets dropped
> off.  That's why the messages are sequentially numbered.

Yeah, I changed it to backup/. instead of just backup... I guess the
first uses maildir and the second uses mh folders.  I prefer maildir. 
=)

-- 
[EMAIL PROTECTED], OpenPGP key available on www.keyserver.net
Freezer Burn BBS:  telnet://bbs.freezer-burn.org . ICQ: 54924721
Webmaster for the Linux Portal Site Freezer Burn:  http://www.freezer-burn.org

Current Linux uptime: 2 days 20 hrs and 37 mins.

Reply via email to