[MlMt] match "contains" condition on whole word only?

Benny Kjær Nielsen mailinglist at freron.com
Mon Nov 6 05:03:42 EST 2017


On 4 Nov 2017, at 15:03, Shoshanna Green wrote:

> I've got a check-before-sending condition set up in 
> messageVerifications.plist that's meant to keep me from sending 
> messages related to the group I'm on the board of from any address 
> other than the one I use for board business. The relevant condition is 
> set up as
>
> 	conditions = "(subject ~ 'board' or #unquoted ~[a] 'board')";
>
> in other words, either the subject or the unquoted body text contains 
> the word "board."
>
> But this condition is also triggered whenever I use a word like 
> "keyboard" or "boardwalk" or "onboarding." Is there a way to restrict 
> it to whole-word matching?

For “Subject”, you can use “Subject ▸ Body ▸ Word”, but 
there is no solution for the other one. Well, it's technically possible 
to introduce a new specifier yourself, but I think that would be 
overkill in this case.

I have an old request for supporting regular expressions when matching. 
That's probably your best hope for the future.

-- 
Benny


More information about the mailmate mailing list