Many Windows users are used to lock their computers with a keyboard combination when they leave their desks, which is a very good practice (not talking about RAM content here, let’s move on!). One thing I’ve got asked a couple of times is how to do the same thing on a Mac, and well the thing is that there are a couple of options to secure your computer when you are away but are not exactly like the Windows.
Because of this I though of writing this article and enumerating the ways you can accomplish this.
- (⌘) + (⌥) + (⏏) : Immediately sleep your Mac.
- (⌘) + (⇧) + Q : Then enter to logout gracefully
- Close the lid of you laptop. D’oh!
- System Preferences -> Mission Control -> Hot Corners… -> Start Screen Saver
- /Applications/Utilities/Keychain Access.app -> Preferences -> Show keychain status in menu bar -> Click -> Lock Screen
- And finally the last method I learned recently with the help of Greg Neagle:
- Open Automator and create a new Service; A services that receives no input in any application.
- System Preferences -> Keyboard -> Shortcuts -> Services; Scroll to the bottom, click on add shortcut for your new service and press your desired key combination.
Here the code portion
1 2 3 4 5