mhonarc-users

Re: separate directories by month? (FAQ?)

1999-09-06 21:56:49
On September 6, 1999 at 11:29, "Peter Seitz jun." wrote:

OK, I thought this would be in a FAQ, and I've seen it asked in the
mailing list archives, and I've skimmed through all the resource
descriptions, but I can't find the answer. How does one go about
configuring MHonArc to build the archives for incoming messages in
separate directories by month?

Here's a script I wrote that would take output from majordomo and send it to mhonarc in month by month archive directories...

Parm 1 is the mailing list name.

#!/bin/sh

BASE=/usr/local/mail/html

if [ ! -d $BASE/$1 ]
then
        mkdir $BASE/$1
fi

TODAY=`date +%Y%m`

if [ ! -d $BASE/$1/$TODAY ]
then
        mkdir $BASE/$1/$TODAY
fi

mhonarc -add \
        -quiet \
        -rcfile ~majordom/html/$1.mrc \
        -outdir $BASE/$1/$TODAY

david

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