Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > running an applescript at startup

running an applescript at startup
Thread Tools
Mac Elite
Join Date: Nov 2000
Location: dark side of the moon
Status: Offline
Reply With Quote
Sep 4, 2002, 09:50 AM
 
ok, im trying to setup an apple script to run everytime i startup the computer. It only needs to run at boot, since i only have one user.

1. In 9 i would simply put something in the startup folder. there is a startup folder in the main library folder, is that where it goes?

2. how to i make the script executable? right now, it says that its been specified as run-only yada yada yada. I dont want to open the script, i just want it to run.

Thanks

There's someone in my head but its not me...
     
Mac Elite
Join Date: Feb 2001
Location: Vancouver, WA
Status: Offline
Reply With Quote
Sep 4, 2002, 03:04 PM
 
First, some questions. What does your script need to do? Do you really need it to run at boot time or would it be better for it to run when you log in? (Of course, if you're the only user and you're using automatic login, boot time and login time are the same.)

If it can run at login, see the Login Items pane of System Preferences.

If you really need to run at startup, see the System Overview document in the developer tools documentation. You'll need to write a shell script, although it can still run an AppleScript via /usr/bin/osascript.
Rick Roe
icons.cx | weblog
     
Mac Elite
Join Date: Nov 2000
Location: dark side of the moon
Status: Offline
Reply With Quote
Sep 5, 2002, 12:12 AM
 
ill try the login. thanks.

shell scripts are a little out of my league =)

There's someone in my head but its not me...
     
Fresh-Faced Recruit
Join Date: Jan 2002
Status: Offline
Reply With Quote
Sep 5, 2002, 04:55 AM
 
Save the script as an application from the script editor in OSX, then add it to the startup items in login system preferrences.
Grant.
     
Dedicated MacNNer
Join Date: Dec 2001
Location: Bolton, UK
Status: Offline
Reply With Quote
Sep 6, 2002, 06:41 AM
 
There is an important difference worth mentioning. If you use the login panel, the script will run as you, the user. If you use the startup items folder (with osascript as mentioned above) it will run as root. Only run things as root if you really need to!

Barney.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -4. The time now is 02:47 AM.
All contents of these forums © 1995-2014 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2014, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2