crontab

from http://ss64.com/osx/crontab.html

Crontab ASCII Art example.

instead of the *, you may wish to use the following shortcut strings:

       string       meaning
       ------              -------
       @reboot       Run once, at startup.
       @yearly       Run once a year, "0 0 1 1 *".
       @annually       (sames as @yearly)
       @monthly       Run once a month, "0 0 1 * *".
       @weekly       Run once a week, "0 0 * * 0".
       @daily       Run once a day, "0 0 * * *".
       @midnight       (same as @daily)
       @hourly       Run once an hour, "0 * * * *".

Also, according to my experience, if you create a script named, say "do-something.sh", it simply won't work because of the .sh extension, so name your crontab scripts without the .sh extension (...and don't forget to shebang and chmod+x your scripts).

Rate this post