Skip to content

Easily executable script file to prevent MacOS sleep for a specified duration

License

Notifications You must be signed in to change notification settings

drq883/TerminAWake

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 

Repository files navigation

Advanced MacOS sleep control

Setup this script to disable MacOS sleep for any specified duration.

Sleep is prevented on battery & while charging, including when a MacBook lid is closed.

Credits

Reddit user bmw3393 schooled me on apps that fail because of bad names and suggested 'TerminaWake' which is such a perfect name 😎 (Also nice logo as TerminAWake)

Setting up the script is easy

  1. Download 'stay-awake' or copy its content into a text editor & save the file as 'stay-awake' (without a file extension)
  2. Run chmod +x [full path to the 'awake' file] to make the file executable. To get the file path: i. Drag the 'stay-awake' file into the terminal window, then delete the [comment] ii. Secondary click on the file and press the option key to reveal the "copy 'stay-awake' as Pathname" option

Running the script

Browse to the 'stay-awake' file and run it using the following examples:

  • ./awake - stay awake indefinitely

  • ./awake 30m - stay awake for 30 minutes

  • ./awake 90s - stay awake for a minute and a half

  • ./awake 24h - stay awake for 24 hours

  • ./awake 1h 15m 30s - stay awake for an hour, 15 minutes & 30 seconds in total

  • ./awake 1m 10s - stay awake for 70 seconds

Future goals

  • Issues

  • Features

    • Convert to MacOS app
      • Share downloadable executable file instead of script that needs to be setup and executed in terminal
      • Create a basic MacOS UI based app

About

Easily executable script file to prevent MacOS sleep for a specified duration

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%