mayoff / suppressRestartEvent

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This project creates a command-line program named suppressRestartEvent. The program installs an event tap that detects and suppresses the event generated by the key combination Command-Control-Eject, which triggers an orderly system restart.

To use it:

  1. Build the project.
  2. Copy the product (suppressRestartEvent) to some stable location.
  3. Change the value of the Program key in com.dqd.suppressRestartEvent.plist to the absolute path of that copy.
  4. Copy the modified com.dqd.suppressRestartEvent.plist to $HOME/Library/LaunchAgents.
  5. Run launchctl load $HOME/Library/LaunchAgents/com.dqd.suppressRestartEvent.plist (or reboot).

About


Languages

Language:Objective-C 100.0%