My list sorting recipe creates new monthly (or daily, or yearly)
mailboxes. <1>
:0
* ! LIST2 ?? ^^^^
{
:0:
$MLDIR/$LIST2/$MYDATE.$LIST2
# if the action failed, probably the directory does not
# exist, so create it
:0eW
{
LOG="FAILED WRITE$NL"
MAKENEWDIR=`test -d $MLDIR/$LIST2 || mkdir -p $MLDIR/$LIST2/`
}
# Now save the message again
:0a:
$MLDIR/$LIST2/$MONTHFOLDER.$LIST2
# If we get this far, something is quite wrong.
# Still failed? Better save the message somewhere we can check it
:0:
{
LOG="FAILED WRITE NEW DIRECTORY$NL"
:0
$MLDIR/FAILED_LIST_SORT
}
}
This works perfectly, btw, and I've never had a message hit the
FAILED_LIST_SORT mailbox. The trouble is, these new folders show up as
unsubscribed, which means that everyday I have to refresh the list of
mailboxes and manually subscribe them.
Is there anyway to create a mailbox in such a way that it is marked as
subscribed? Is there some shell level command I can run inside the
procmail recipe that would do this? I looked at the files themselves
and I don't see anything obvious, which makes me think it is the imap
server that is keeping the info somewhere outside the mail directory.
I am using uw-imap
<1> Check the list archives if you are curous how this works. a search
for "mkdir" will probably be sufficient.
--
The older you get the more you need the people you knew when you were
young.
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail