OT [??} .procmailrc question
![](https://seccdn.libravatar.org/avatar/b157673ba3cb05641c32f6b410da2c37.jpg?s=120&d=mm&r=g)
Hi, I want a particular type of emails to be sent to a folder. Like, if I have files coming from abc@xyz.com OR having subject [SLE] or with "free prizes" in the body of the message, then they all should go to free-time folder. The rule :0 ^From.:*abc@xyz.com* ^Subject.:*\[SLE\]* B *free*prizes* free-time Shall implement an AND in the conditions, while I seem to need an OR here. Is it even possible to do it within one single rule? Do enlighten, -- Rohit +9122 5692 2101 G9,Floor-1,Chandivali : SDE : TLSI : 9821394599@bplmobile.com The information below is compulsorily added for non-mahindrabt recepients. ********************************************************* Disclaimer This message (including any attachments) contains confidential information intended for a specific individual and purpose, and is protected by law. If you are not the intended recipient, you should delete this message and are hereby notified that any disclosure, copying, or distribution of this message, or the taking of any action based on it, is strictly prohibited. ********************************************************* Visit us at http://www.mahindrabt.com
![](https://seccdn.libravatar.org/avatar/c044c5075a60de3d119592c094323fa3.jpg?s=120&d=mm&r=g)
* Rohit
I want a particular type of emails to be sent to a folder. Like, if I have files coming from abc@xyz.com OR having subject [SLE] or with "free prizes" in the body of the message, then they all should go to free-time folder.
The rule
:0 ^From.:*abc@xyz.com* ^Subject.:*\[SLE\]* B *free*prizes* free-time
Shall implement an AND in the conditions, while I seem to need an OR here. Is it even possible to do it within one single rule?
Do enlighten,
Explained very well in TFM, man procmailrc, man procmailex. Many
situations and examples are presented at Nancy McGough's excellent web
site, http://www.ii.com/internet/robots/procmail/qs/.
Unix wide OR is "|". You will find it in the locations mentined above.
Procmail Mailing List
![](https://seccdn.libravatar.org/avatar/1ae92035c03829e23a08fda96a78b309.jpg?s=120&d=mm&r=g)
Hi,
I want a particular type of emails to be sent to a folder. Like, if I have files coming from abc@xyz.com OR having subject [SLE] or with "free prizes" in the body of the message, then they all should go to free-time folder.
The rule
:0 ^From.:*abc@xyz.com* ^Subject.:*\[SLE\]* B *free*prizes* free-time
Shall implement an AND in the conditions, while I seem to need an OR here. Is it even possible to do it within one single rule?
You can use single rule or multiple rules. One of the best documents about procmail is at http://pm-doc.sourceforge.net/pm-tips-body.html. You question is described in sections 6.17, 6.18 and 6.19. HTH -- Bye, Ivan Gustin -- Ovaj mail provjeren je antivirusnim programom ESET NOD32 prilikom prolaska kroz mail server. This mail has been scanned by antivirus software ESET NOD32 during passing through mail server.
participants (3)
-
Ivan Gustin
-
Patrick Shanahan
-
Rohit