
Regular Expressions for Conditions and Submailboxes
Reported by Vadim Belobrovka | January 6th, 2016 @ 02:41 PM
Hi,
-
Please provide support for Regex in Smart Mailbox Conditions. "Contains" is just not cutting it.
-
Another huge one is Regex support in Submailboxes - I would like to be able to group by unique value that is extracted via a REGEX. For example github emails that are coming in due to a given pull request communication come in this format:
"[repo name] pull request name"
I would like to be able to extract repo name and group all the github communication emails by those repo names via Submailboxes.
All hail MailMate!
Thank you very much!
Vadim
Comments and changes to this ticket
-
Chris February 8th, 2017 @ 12:41 AM
Hi, I endorse the request for regex support in conditions.
In addition, I suggest the following:
1) add condition "Value in Header"
2) allow user to enter header elements (e.g., custom x-headers) not found in current mails while setting up rules
3) interface to manage, import and export rules or rulesets, so that you can easily assign them to different foldersFortunately, one can edit the relevant config files; that helps a lot with 2) and 3).
May I use the opportunity to ask what "any address" includes?
-
-
Tee Yen Ng November 29th, 2017 @ 06:01 AM
FWIW, I was just looking for a way to do just this. Turned up this ticket, but found a semi-solution subsequent. Thought it best to leave a bread crumb for anyone else searching :)
You can use regexp in the Mailbox name format: entry under sub-mailboxes.
I still end up with a submailbox for each individual subject, but the mailbox names are displayed as per the regexp. For example:
${subject.body/(.*)RFI[ -]*([0-9]+)\s*(.*)/RFI-${2} - ${3}/}
Would be curious if there is a way to use the custom mailbox name format as the unique value!
Found this over here:
http://blog.froztbyte.net/2016/12/mailmate-submailbox-snr-hack/ -
Tee Yen Ng November 29th, 2017 @ 06:43 AM
OK dug further, and turns out this is a common thing.
Has been solved here:
https://lists.freron.com/mailmate/2012-February/000197.html
Other commentary along the way:
https://lists.freron.com/mailmate/2014-March/002252.html
https://lists.freron.com/mailmate/2017-June/008208.html -
benny November 29th, 2017 @ 12:35 PM
- State changed from new to accepted
@Tee Yen Ng: Thanks for the updates and for finding the relevant information yourself. The low-level editing of custom specifiers is still the only way to get regular expressions. I'm thinking it'll stay this way, but I might eventually add a GUI for creating new specifiers more easily. This is what the “accepted” state is for in this ticket.
Sorry for not replying to this ticket earlier on.
-
Muescha January 25th, 2018 @ 12:58 AM
i tried all rules for submailbox:
${subject.body/([\[\]a-zA-Z]*).*/${1}/}
but for a
"[abc] Subject"
i always get an list of unique folders with always one entry (like the screenshot)i get it not working
But i find out just Change it to
"subject -> blob"
i get a list of the [abc] selectors.BTW:
- i think there should be a better documentation of all the hidden features
- editing the plist fildes are to complicated just now :(
-
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
Mac OS X email client.