Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to execute a crontab (OS X 10.9) when mac is turned on again

Tags:

cron

I was wondering how I could execute a crontab which usually occurs when Mac is turned off (not just asleep). As for documentation, OS X skips crontabs if the machine is off. Is there a way to have crontabs to be executed once mac turns on again?

Thank you.

like image 921
Barry Avatar asked Oct 19 '25 01:10

Barry


1 Answers

You can use: @reboot

 @reboot /path/to/script

Source Apple's Crontab Man Page

like image 59
gtgaxiola Avatar answered Oct 22 '25 06:10

gtgaxiola