Inspired by caffeinate, Wakeful prevents data corruption in long-running processes like bitcoin-node-docker by ensuring graceful shutdown before sleep.
If you wish to support this project, please star repo and consider a donation.
$ git clone https://github.com/sunknudsen/wakeful.git
$ cd wakeful
$ swift build --configuration release
$ sudo cp .build/release/wakeful /usr/local/binBuild and install Wakeful using Homebrew
$ brew install sunknudsen/tap/wakeful$ wakeful --help
Usage: wakeful [options] <command> [arguments...]
Options:
-d, --display Prevent computer and display from sleeping
-g, --grace-period <seconds> Grace period for child process termination (default: 60)
-h, --help Show this help message and exit
-v, --verbose Make operation more talkative
-V, --version Show version number and exit
Example: wakeful watch ls -la
Prerequisites:
- Create “App Manager” API key on App Store Connect
- Run
xcrun notarytool store-credentials wakeful-notarytool- Run
cp .env.sample .envand add your “Developer ID Application” signing identity
$ source .env
$ swift build --configuration release
$ codesign --options runtime --sign "$CODESIGN_IDENTITY" --timestamp .build/release/wakeful
$ ditto -c -k --keepParent .build/release/wakeful wakeful.zip
$ xcrun notarytool submit wakeful.zip --keychain-profile "wakeful-notarytool" --wait
$ rm wakeful.zip