[Mailman-Users] mhonarc recipe?

Michael Brennen mbrennen at fni.com
Sat Dec 2 05:32:16 CET 2000


On Fri, 1 Dec 2000, Jerry Adlersfluegel wrote:

> Does anyone have a working mhonarc installation they could
> share? I am interested in how to set Mailman to archive with it,
> including private archives and decoded MIME attachments. Also if
> the archive format were similar to the builtin archive style,
> that would be nice.

For straightforward archving, I subscribe a special address to the
mailman list.  Then, in the .procmailrc file for that special
account I have the following:

:0
* ^.*the_list_name@
|/full/path/to/archives/mh


The 'mh' script is below.  It automatically archives to a folder
YYYYMM under the main .../archives directory.  The index.php3 page
in .../archives automatically builds the list of available archived
months, so the system maintains itself.

   -- Michael


#!/usr/bin/perl

$mn=(localtime())[4]+1;
$yr=(localtime())[5];
$yr=1900+$yr;
$mdir=sprintf("/full/path/to/archives/%4d%02d",$yr,$mn);
umask(022);
if ( !(-e $mdir) ) {
        mkdir($mdir,0755);
}
open(MH,"|/path/to/mhonarc -umask=022 -quiet -add ".
        "-rcfile /usr/local/lib/MHonArc/resource/list_name.rc ".
	"-outdir $mdir -- -");
while (<>) {
        print MH;
}
close MH;





More information about the Mailman-Users mailing list