Mail archiving
Tim Potter
tpot at samba.org
Thu Sep 5 14:38:12 EST 2002
On Thu, Sep 05, 2002 at 02:29:54PM +1000, Tim Potter wrote:
> > As everyone knows, mutt doesn't handle large mailboxes very well (at least
> > not in mbox format). What I would like to do is to automatically move mail
> > older than 3 months to another folder. While this is possible in mutt by
> > typing the right commands, does anyone know a non-interactive way of doing
> > it?
>
> I use grepmail and a cron job.
>
> lockfile foo.mbox
> grepmail -d "since 3 months ago" foo.mbox > foo-new.mbox
> [ $? = 0 ] && mv foo-new.mbox foo.mbox
> rm -f foo.mbox.lock
Hmm - OK this doesn't do exactly what you want. It was copied from a
script that I use to delete my old mail rather than archive it. Who
reads old mail anyway? (-:
Tim.
More information about the linux
mailing list