Re: Scripting Mail
Re: Scripting Mail
- Subject: Re: Scripting Mail
- From: John <email@hidden>
- Date: Mon, 14 Jan 2013 10:44:00 -0500
Maybe you can write a Google apps script for your gmail account. Here is an example:
http://www.johneday.com/422/time-based-gmail-filters-with-google-apps-script
https://developers.google.com/apps-script/service_gmailJohn D.
On Mon, Jan 14, 2013 at 10:32 AM, James Roberts
<email@hidden> wrote:
Yvan,
I agree, that scanning the complete inbox is not the best solution. For most of my accounts it’s not a big problem, they are fairly low volume. The big problem is my Gmail account. Gmail has an mailbox called ‘Starred’ that holds all flagged msgs but it is not a real mailbox. Every time I try to do anything with it applescript errors ‘can’t get mailbox’. I need a solution that will work with iOS as well and moving msgs around to different folders seems to defeat the purpose of flagging IMHO.
If there was some way to change the scheduling priority (nice) of the script that would be great. I don’t care if it takes and extra few seconds to run if it doesn’t pull 100% of the cpu and drag mail to a halt.
James Roberts
"Nothing travels faster than the speed of light, with the possible exception of
bad news, which obeys its own set of laws" ~ Douglas Adams
Le 14/01/2013 à 02:46, James Roberts <
email@hidden> a écrit :
Merci Yvan,
That stabilized the run time to about 5 sec. It still hangs Mail’s GUI but only long enough to be annoying not unworkable :-)
Can you explain what is happening with calling the script with ‘run’. I noticed the script dose not appear as it’s own process now, just mail cpu jumps to 100%.
Hello
I don't know the technical explanation but when scripts are saved as applications, they behave slower than when they are saved as scripts.
I learnt the tip ”encapsulate them in a script wraper“ one or two years ago.
It's really efficient and I use it for all my scripts.
It's just annoying during the coding phase because what is done in the script object doesn't appear in the Event log.
This is why I insert the script wraper only when the code is OK.
Back to your script.
From my point of view, it's odd to scan every messages every minute.
I feel that it would be more efficient to use a rule storing flagged messages in a dedicated mailbox.
So your script would just have to treat the contents of this box.
Yvan KOENIG (VALLAURIS, France) lundi 14 janvier 2013 10:17:04
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (
email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden