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

Post2Fix/TerminalWake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

62 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Advanced MacOS sleep control

Advanced macOS sleep manager, based on open-source, enterprize and user friendly, Bash scripts that can also be used directly.

Features

  • User guiding interactive terminal app
  • Disable sleep indfinitely at launch (if no delay timer is specified)
  • Specify times disable sleep in hours, minutes and seconds at launch (e.g. ./terminawake 1h 30m 15s), & during runtime (coming soon).
  • Prevent sleep on battery & while charging, including when a MacBook lid is closed.
  • Press 'return' to enable sleep (on-screen instruction)
  • Displays total sleep delay in seconds after launch
  • Unique, and very simple deployment (single Terminal command (without password) to setup from the downloaded repo)

Easy setup

  1. Download this repository to your Downloads folder
  2. Paste & run this command in your Terminal (use the copy icon)
unzip ~/Downloads/TerminAWake*.zip -d ~/ && chmod +x ~/TerminAWake*/setup.sh && ~/TerminAWake*/setup.sh && sudo ~/TerminAWake*/terminawake.sh
  • To start a Terminal (Press F4 or [command + space] & search 'Terminal')

Launching the app

  • A shortcut was created where you chose to deploy the app
  • Launch the script using sudo ./terminawake from its folder (or use the absolute path to teminawake.sh)

Using the app

The app has a UI that guides you on how to use it

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

Known issues

  • Locking a Mac when the screen turns off
    • I'm unaware atm about a way to lock a Mac using Terminal commands. There's a screensaver value that controls the delay to ask for a password after the screen turns off (or after the screensaver is enabled). MacOS security blocks the terminal from changing that value. It might be possible to do by giving Terminal accesibility rights. But the program

Contributing

Please feel free to contribute in your favorite way :) It would be appreciated.

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