On Sat, Jan 24, 2009 at 09:17:42AM -0500, Patrick Shanahan wrote:
* Xavier Maillard <xma(_at_)gnu(_dot_)org> [01-24-09 04:48]:
I am trying to have a "general" recipe to do something based on
the X-BeenThere header.
Say I have a header like this one:
X-BeenThere: lolica(_at_)lolica(_dot_)org
I want procmail to "automagically" store any messages to this
list into list.org.lolica.lolica
If the header refers to clsql(_at_)b9(_dot_)com, I want list.com.b9.clsql
etc...
# -------------------------------------------------------
:0:
* ^X-BeenThere:(_dot_)*lolica(_at_)lolica(_dot_)org
$MAILDIR/list.org.lolica.lolica
# -------------------------------------------------------
Hi, Patrick,
Well, this approach is a little unusual, for the following
reason: MAILDIR, in addition to being a "magic" invocation
in procmail to chdir, also represents by the current working
directory. So there is no difference between the folder
$MAILDIR/list.org.lolica.lolica
and the folder
list.org.lolica.lolica
Moreover, I presumed the OP wanted to know how to automate the
distination folder. (Hence the request for a "'general' recipe.")
I think he wants something like this:
:0:
* ^X-BeenThere:.*\/[^ ]+
list.$MATCH
(Inside the brackets are a caret, a space, and a tab.)
Dallman
____________________________________________________________
procmail mailing list Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail