imap autoarchive
imapautoarchive@joeshmoe.com
a utility for automatically archiving old mail from one imap folder to another.
  A PRODUCTION OF 
     
 

what it does:
imap autoarchive is a perl program that allows you to automatically move, copy, or delete mail on an imap server based on when it was received. it is modeled on the autoarchive feature of microsoft outlook. as an example, you can configure imap autoarchive to move all mail older than 30 days from your inbox folder to an inbox-oldmail folder. This allows you to keep the size of your folders managable without having to manually move messages.

requirements:
perl 5
the Mail::IMAPClient perl module (available at CPAN)

the license:
this program is copyright (c) 2001 by joeshmoe.com. it may be freely used for all commericial and non-commercial purposes. you may redistribute imap autoarchive (in original or modified form), however, it is requested that you notify joeshmoe.com at license@joeshmoe.com before you do so. you may not charge money for imap autoarchive (or derivative works) without the express permission of joeshmoe.com

it is requested that all users who modify this source code send their changes to joeshmoe.com. bugs reports and modifications can sent to bugs@joeshmoe.com.


how to use:
running imap autoarchive is easy. the syntax is:

      % imapautoarchive.pl config-file

where config-file is the path to the imap autoarchive configuration/rules file. this file contains a set of rules that tell imap autoarchive how to behave. click here for a sample config file.

it is recommended that imap autoarchive be run regularaly from cron (otherwise it's not really autoarchive).


download:
current version: 1.0beta

imapautoarchive-1.0b.tar.gz (3 KBytes)


known issues and caveats:

- imap autoarchive seems to have trouble moving more than ~800 messages at a time. this seems to be caused by a limitation of the Mail::IMAPClient module. It would be nice if imap autoarchive worked around this limitaiton.

- the copy feature of imap autoarchive is really dumb. it will happily make multiple copies of messages. this makes it nearly useless unless you run it only once with a given copy rule.

- when moving and deleting messages, you must use the with expunge rule option to truly delete the messages from the original folder. otherwise, the messages will only be marked for deletion (but will remain in the folder). note that with expunge will delete all messages that are marked for deletion (not just the ones that you moved/deleted with imap autoarchive). don't blame me, blame imap.

- imap autoarchive is not smart about dates and times: a year is 365.25 days days. a month is 30.43 days (1/12th of a year). a day is 86400 seconds.


changelog:

1.0beta
initial relase

last updated: 2001-Dec-02   /   copyright (c) 2001 joeshmoe.com