procmail
[Top] [All Lists]

Re: Procmail 4.0 WishList

2004-06-26 14:49:58
On Jun 26, 2004, at 11:11 AM, Google Kreme wrote:
On Sat, 26 Jun 2004 09:39:21 -1000, Michael J Wise <mjwise(_at_)kapu(_dot_)net> wrote:
1) Lose the damned ":0" for a start! Put the options after the thing it
mods.
You need to something to delineate where a recipe starts.  :0 is as
good as anything.

I was proposing a blank line.

Maybe just a :
not sure what you mean by "Put the options after the thing it mods"

See the examples.
:D would be a case-sensitive match, for instance.

2) Replace "*" with ":"?
Change for the sake of change?

Nope.
The "*" seemeth a bit overloaded to me.
But this is a "Whatevahs" suggestion. I don't as such care.

3) Support [0-9a-f]{12}
and [a-z]{5,}  [a-z]{,5}and other forms.  Agreed.

Yeah.

4) Support DNS lookups directly.
I don't think so.  procmail is not a dns lookup tool, and there are
ways to do dns lookups if needed.  No reason, I think, for it to be
builtin to procmail.

Each DNS lookup spawns a sub-shell.
For each piece of email received, I do a BUNCH of DNS lookups on it.
This Is Expensive.
And something that Procmail does a lot of in many venues.
It should be possible to do inexpensively.

And no, the MTA is NOT the right place to perform these checks in this case.

5) Maybe support some sort of "Function" definitions.
6) ">" indicates final delivery ("we're done").
7) "+" indicates non-final delivery (aka ":0 c").
Change for the sake of change again?

No, functionality, and clearness of expression.

Support for multiple actions would be very useful.

{ yeah. }

8) put formail into the code so you don't need to spawn another shell.
This is probably a good idea.  I'm sure it wasn't done initially to
keep the size of procmail down.  However, it might mean procmail is
always consuming much more reesources than would be used with the
current split executables.

Yeah.

9) Use $1, etc. instead of "\" + "/".
full awk-like pattern matching would be very nice to have, agreed.

I'd suggest "Standardizing" on PCREs, perhaps as a necessary package to
include into the source.

10) FULL PCREs instead of "Almost". Except maybe use " " as a synonym
for \s.

Oh yeah, blank line fulfills the same function of ":0" in starting a
recipe.
No, I really disagree with that.  SOME start of recipe marker is
needed, and white space should not be required:

LOG="Log this"

Not a recipe.

YEAR=`date '+Y'`

Not a recipe.

* From:(.*\<)?bob(_at_)aol\(_dot_)com
bob.mail

where's the recipe start?

The line that begins, "* From:".

if you want to consider the * to be the
start of recipe that's fine, I suppose, but you still need some way of
limiting the scope of the recipe.  (you want the recipe to only look
at the header, or only the body, or only the MIME headers, etc)

A blank line "resets" the recipe mode.

Oh yeah, some obvious way of specifying "or" would be nice, too.
Just for the neophites. The rest of us know "|".
'|' is the standard way to specify or.  Someone who can't handle that
has no business in the shell, much less in procmail.

The thing is, I keep seeing rule cascades that start with leading "!"s.
While that works, it's ... kinda syntactically ugly.
And yes, it could be rewritten, I agree.

ISTM that it would be nicer if you could say something like, "If the previous rule failed, don't stop, try this, but if it succeeded, don't bother with this line."
But this is another "Whatevahs" idea. Doesn't matter, I guess.

a minor addition, I would like to see two LOG commands, LOG and LOGN.
LOGN would log with a NL (like echo) and LOG would log like LOG (echo
-n).  Also, basic understanding of MIME would be nice.

MIME headers included in the definition of "H"?
Ability to match against the 'de-MIME-ed' attachments?

That's just a few minutes day-dreams, but ... methinks that Procmail is
overdue for an overhaul, and this is just my personal wishlist.
Well, who's going to write it?
It is open source, right?  Get cracking!

Methinks that there is a need to agree on a future vision, first.
Otherwise, I'll be the only one using it.

Aloha mai Nai`a!
--
"Please have your Internet License             http://kapu.net/~mjwise/
  and Usenet Registration handy..."


____________________________________________________________
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

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