procmail
[Top] [All Lists]

Re: The Safe backup in procmailex

1997-05-30 00:57:00
On Thu, 29 May 1997, David W. Tamkin wrote:

We did discuss this once upon a time, and I wrote (with input from Stephen
and from some other people) some code for it that ought to be in the list's
archives somewhere.

I believe I have one of the solutions that was posted.

The most important question first: should new messages be placed at the
beginning or the end of the backup folder?  Either way, the code for one is
rather different from the code for the other, so you need to make a choice.

I recall Pine being discussed, which let's you sort messages in the folder
index, at which point the above question isn't an issue -- since Pine will
resort anyhow.

What I use is below. The problem with it is that it takes an awefully long
time (understandably, because of the number of messages I am backing up).
If anybody can think of even minor performance improvements I Could make,
it'd be greatly appreciated.



BACKDIR=$HOME/Misc/Backup

BACKGFILE=$BACKDIR/mail.general.backup
TEMPGFILE=$BACKDIR/temp.general.backup
maxgbackup=1750

:0Wc:Misc/Backup/lock.mail.backup.general
| cat - $BACKGFILE | $FORMAILZ -${maxgbackup}s > $TEMPGFILE ; \
  mv -f $TEMPGFILE $BACKGFILE



 ------------------------------------------------------------------------- 
 | Brock Rozen | brozen(_at_)webdreams(_dot_)com | 
http://www.webdreams.com/~brozen | 
 ------------------------------------------------------------------------- 


<Prev in Thread] Current Thread [Next in Thread>