|
|
Shell Script
Could one of you guys spell out specifically how to do what you're recommending? I'm a longtime Mac user, but haven't been much of a nuts-and-bolts guy in the past, I'm afraid, so I'm not entirely sure, for example, how to save as a shell script or add to cron or...
Shell Script
To create a shell script create a new text document in TextEdit, it must be text or it wont work.
chmod is missing
Hi,
you will have to change the mode of the file to "executable", which is done best by issuing chmod 755 filename_with_extension_if_any at the commandline. Otherwise the shell will not execute your script. The suggested mode means: owner can read, write and execute, groupmembers and others can execute and read the file but not change it. Some words for the unix-challanged :-) A shell is the programm you can interact with when opening the terminal. It usually provides access to builtin commands and to commands that are individual programs. A shell-script is just a plain textfile containing commands that can be executed by the shell, in fact, if you enter all the lines in the textfile by hand on the commandline the shell would execute them, too. However, reocurring tasks should be automated by creating a script, that can be used like any other command once you have changed the file-permissions to executable. You might wonder what the first line #!/something/somethingelse means. It just tells which shell to use for executing the script. Since there are a lot of shells (bash/tcsh/sh) and scripting languages (PERL,Python) around you can write your script in any of them and just tell #!/where/it/is in the first line. And cron is just a common way to execute commands at specific times. You can tell the system (specifically the cron-deamon) to execute a command every 30 minutes or every Friday at 1500. ChronniX is a convenient tool to use cron without touching the evil commandline. I apologize for any confusion I have caused, #!chris |
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.42 seconds |
|