Michael Andersson asked,
| OK, I've looked through the man page, and it seems that multiple
| conditions in a recipe are AND-ed. How does one OR several conditions?
If possible, one combines them. The general case of how to OR uncombinable
conditions is another matter, that I won't need to get into here.
First, I see the way you are capitalizing "^FROM". If you thought that there
was a special ^FROM token that expands like ^TO and ^TO_, there isn't (and
Stephen has said that there never will be). If you want to match on either
the Unix From_ line or the RFC822 From: header, use ^From[: ] -- I suggest
specifying the character after the m in case someone decides to get cute and
put in header lines like these:
Fromme: should have stayed on the wharf
Fromage: camembert today, brie tomorrow
| Is there some way to combine them? It would be great to be able
| to put together something like this:
| * ^FROM.*nasa.gov
| * ^TOssrt-news
| * ^TOJPLNews
| * ^FROM.*NASANews
| If my understanding is correct, however, this will only work if
| the email fulfulls all four of those conditions...
Right. They'd be ANDed. To OR them, since they are non-negated regexp
conditions, just glue them with pipes:
* ^From[: ].*nasa\.gov|^TOssrt-news|^TOJPLNews|^From[: ].*NASANews
It can be further reduced to this:
* ^TO(ssrt-|JPL)news|^From[: ](.*\>)?nasa(\.gov|news)
You might want to file mail from other lists (such as this one) first just in
case somebody posts to one of them from an address in the nasa.gov domain.