Procmail Recipie For FreeBSD Lists?
Drew Tomlinson
drew at mykitchentable.net
Thu Jul 3 14:26:51 PDT 2003
----- Original Message -----
From: "Paul Chvostek" <paul+fbsd at it.ca>
To: <freebsd-questions at freebsd.org>
Sent: Thursday, July 03, 2003 10:37 AM
> On Thu, Jul 03, 2003 at 10:12:22AM -0700, Drew Tomlinson wrote:
> >
> > :0:
> > * ^List-Id:[^<]+<freebsd-\/[^.]+
> > Maildir/FreeBSD/$MATCH/new
> >
> > And I'm getting messages like this in my procmail log:
> >
> > procmail: Assigning
"PATH=/home/drew/bin:/bin:/usr/bin:/usr/local/bin"
> > procmail: Lock failure on "Maildir/FreeBSD/alpha/new.lock"
> > procmail: Error while writing to "Maildir/FreeBSD/alpha/new"
> >
> > OK, I assume the error is because Maildir/FreeBSD/alpha/new does not
> > exist. How can I get procmail to create the directory it needs?
>
> As you no doubt read on the procmail manpage:
>
> | If the mailbox name ends in "/", then this
> | directory is presumed to be a maildir folder; i.e., proc-
> | mail will deliver the message to a file in a subdirectory
> | named "tmp" and rename it to be inside a subdirectory
> | named "new".
>
> Now ... I obviously don't use maildir format, but to me, this would
> imply a format something like:
>
> :0
> * ^List-Id:[^<]+<freebsd-\/[^.]+
> FreeBSD/$MATCH/
>
> I'm assuming that the leading "Maildir/" is redundant, as is the
pointer
> to the "new" folder.
Thanks for pointing out my oversight and all of the help so far. I've
added the "/" and now my recipe is:
:0
* ^List-Id:[^<]+<freebsd-\/[^.]+
/Maildir/FreeBSD/$MATCH/
However I get these messages from the procmail log:
procmail: Matched "test"
procmail: Match on "^List-Id:[^<]+<freebsd-\/[^.]+"
procmail: Unable to treat as directory "/Maildir/FreeBSD/test"
procmail: Assigning "LASTFOLDER=/Maildir/FreeBSD/test"
procmail: Opening "/Maildir/FreeBSD/test"
procmail: Error while writing to "/Maildir/FreeBSD/test"
I've tried without the leading "/", without the Maildir, and without
"/Maildir/" but I keep getting the same type of error. Maildir is owned
by me and is mode 700. I tried changing to 777 but that didn't help so
I put it back to 700. According to the man page, the directory should
be created if it doesn't exist. From the man page:
If the mailbox is specified to be an MH folder or maildir folder,
procmail will create the necessary directories if they don't exist,
rather than treat the mailbox as a non-existent filename.
I feel I am close. Can anyone enlighten me and point out what I'm
missing?
Thanks,
Drew
More information about the freebsd-questions
mailing list