• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Rebooting a Mac with a Mail Rule
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Rebooting a Mac with a Mail Rule


  • Subject: Re: Rebooting a Mac with a Mail Rule
  • From: "Stockly, Ed" <email@hidden>
  • Date: Wed, 15 Mar 2017 22:30:24 +0000
  • Thread-topic: Rebooting a Mac with a Mail Rule

You might try sending adding a "sleep 10;" to the front of your shell
command and then ignore its output ("> /dev/null" added to the end, IIR).

That would give your script time to quit and mail would know the rule
finished without interruption.









On 3/15/17, 3:21 PM,
"applescript-users-bounces+ed.stockly=email@hidden on
behalf of debt"
<applescript-users-bounces+ed.stockly=email@hidden on
behalf of email@hidden> wrote:

>> On Mar 15, 2017, at 1:09 PM, Tom Robinson <email@hidden>
>>wrote:
>>
>> That’s pretty nasty on your GUI apps, they don’t get a chance to quit
>>properly.
>
>	I actually have code in the AppleScript that quits the open apps, so
>that’s not a problem here.
>
>> Does OS X relaunch every app if you reboot from command line?  Maybe
>>that was causing the issue — reboot app was being reopened.
>
>	I haven’t tried that, but in my situation, I have a few apps in login
>items that start up automatically, since it’s a remote machine.  However,
>the reboot app wasn’t one of them.  As I posited before, I think the
>problem is actually with (that version of?) Mail and how it handles
>external scripts (apps?) called by a rule.  Every time it would reboot,
>it kept trying to download the same message and triggering the
>AppleScript.app each time.  Not sure how I can prove that, though.
>
>	There was another problem also.  In the reboot app, I had another do
>shell script calling a Perl script that would send me an email letting me
>know the status, and that got hung up with an error that it couldn't make
>an SMTP connection.  Once I placed the script directly in the Mail rule,
>everything worked properly.
>
>Marc
> _______________________________________________
>Do not post admin requests to the list. They will be ignored.
>AppleScript-Users mailing list      (email@hidden)
>Help/Unsubscribe/Update your Subscription:
>imes.com
>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


References: 
 >Rebooting a Mac with a Mail Rule (From: debt <email@hidden>)
 >Re: Rebooting a Mac with a Mail Rule (From: Tom Robinson <email@hidden>)
 >Re: Rebooting a Mac with a Mail Rule (From: debt <email@hidden>)

  • Prev by Date: Re: Rebooting a Mac with a Mail Rule
  • Next by Date: Re: Rebooting a Mac with a Mail Rule
  • Previous by thread: Re: Rebooting a Mac with a Mail Rule
  • Next by thread: Extract Handler-Calls from AppleScript Libraries with AppleScriptObjC
  • Index(es):
    • Date
    • Thread