Created
October 19, 2017 08:06
-
-
Save nandff/595198b314e1ed7d407ff54fc2f45481 to your computer and use it in GitHub Desktop.
macos: zsh script template: prevent idle sleep
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/zsh | |
{ | |
! (( W_CAFFEINATE )) && [[ -x =caffeinate ]] && W_CAFFEINATE=1 exec caffeinate -u -d $0 $* | |
# main code here | |
exit $? | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment