BlueM / cliclick

macOS CLI tool for emulating mouse and keyboard events
https://www.bluem.net
Other
1.59k stars 116 forks source link

How to schedule a task ? #160

Open nemoleo opened 1 year ago

nemoleo commented 1 year ago

I have seen there is a 'w' command to excute command after a while, but if i wanna to schedule a task happen just in 7:00:00. which command could make this happen ?

BlueM commented 11 months ago

Sorry for the late answer. You could use the sleep command to delay execution. Not what I’d call elegant, but should work. In your case, with 7 hours (= 25,200 seconds) this could be used like …

sleep 25200 && cliclick c:123,456

Disclaimer: I’ve never used sleep with a time that long. And of course, your Mac would have to be awake at that time.