Skip to content

Instantly share code, notes, and snippets.

@brianewing
Created October 22, 2013 16:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brianewing/7103939 to your computer and use it in GitHub Desktop.
Save brianewing/7103939 to your computer and use it in GitHub Desktop.
Lock your Mac by pressing power button
Install "PowerBlock" (freeware) from this site: http://www.irradiatedsoftware.com/labs/
Choose "Run AppleScript when power button is pressed"
Make it run this AppleScript:
do shell script "open /System/Library/Frameworks/ScreenSaver.framework/Versions/A/Resources/ScreenSaverEngine.app"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment