Solved

Scripting the finder with Applescript in OS X (10.3.x)

Posted on 2004-08-09
4
411 Views
Last Modified: 2010-04-29
In OS X (10.3) I cannot figure out how to write an Applescript to restart an unattended computer (at a scheduled time). Using the "restart" command (as in OS 9) will only bring up the restart/shutdown dialog box.  I am not sure how to tell the finder to ignore the dialog.
0
Comment
Question by:ravenbio
  • 2
4 Comments
 

Expert Comment

by:mbarkdull
ID: 11758888
The way I would recommend is send the following command to the terminal as sudo.

Be warned:  Scripting a Super User password is not recommended by many experts.

sudo shutdown -r now
********

Not exactly sure how AppleScript handles terminal commands and input to it.  I'll see if I can find out.  It would be nice if the password could be encrypted in the script as well.
0
 

Author Comment

by:ravenbio
ID: 11759023
Unfortunately, I don't have a clue as to how I would script the terminal...
0
 
LVL 23

Accepted Solution

by:
brettmjohnson earned 250 total points
ID: 11759338
> Unfortunately, I don't have a clue as to how I would script the terminal...

Ah, but Dr John Trimmer does:

http://www.osxfaq.com/Tutorials/as_unix/index2.ws

0
 

Author Comment

by:ravenbio
ID: 11759976
Actually, that link is quite useful, thanks!
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

If you other experts are anything like me you are always looking into and testing out new features. While I was doing some research one day I ran across an app that I installed on my Mac and used as a security system. Mac OS X: SecureHome uses your …
This article describes in detail how to set up the iPad in the Enterprise using iPCU aka iPhone Configuration Utility.  This could also be used for the iPhone although I have not detailed out any differences. Preparation as an iPad Administrator:…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now