procmail
[Top] [All Lists]

Re: substituting for dirname

1998-02-08 13:41:32

David:
        So are you suggesting this? (assuming me do not want to do a  
recursive INCLUDERC)

:0
* ^(To|Cc):.*luomat\+()\/.*
{
        
        :0
        * MBOX ?? ^^\/.+/
        {
                DIR=$MAILDIR/$MATCH

                :0ic
                * ? test ! -d "$DIR"
                | mkdir -p "$DIR"
        }

        
        # NOTE: I want to keep this check here in case
        # there is a directory with the same name
        # that I wanted for the mailbox, ie if I use
        # luomat+lists+procmail and someone sends mail
        # to luomat+lists
        :0w :
        * ? test -d ${DIR} -a ! -d $MBOX
        $MBOX
        
        
        # If the message has not been delivered by now,
        # send it to $DEFAULT
        :0 :
        $DEFAULT
}


Questions:
        What happens when there is just one + sign?
        
        What happens when I am only one of many people listed on the 'To|Cc' 
line?
        

Thanks.... I've been meaning to do this myself
TjL

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