I use google email as my primary email. It works pretty good except that the filters are very limited as to what they can do (no regex's for example).
I get lots of messages filtered into Spam folder. The problem was I was getting so many in Spam folder, it was hard to find the ones that should not be in the Spam folder. I wanted to trash all the messages in my Spam folder that had non-ASCII (emojis, etc.) characters in the sender or subject lines. This would only leave a few messages in the Spam folder for me to review. There is no way to do this with the limited Gmail filters.
Finally decided to look and found out that Google does provide a really cool option to solve this problem. You can write a Google Apps Script (javascript), give it a trigger (e.g once an hour), and voila, you can filter on anything you want pretty much as javascript is a full language, not a very limited filter. Took a few revisions, but now I have a javascript function that runs every hour and checks all messages in my Spam folder and any that have non-ASCII characters in the sender or subject lines are automatically moved to trash.
Think about this. I have access to a full language (javascript) where I can write functions that run somewhere on google's servers to manipulate my mail however I want. For me it was a simple filter, but if I was still working and getting notification emails from systems, this would be a great way to automatically process the notifications.

0 Comments:
Post a Comment