Can I restore pre-Mavericks power key behavior?

Mavericks changed the behavior of my MacBook Air's power key to put the Air to sleep immediately when pressed briefly. Prior to Mavericks, the power key would summon the Shut Down dialog.

As detailed in OS X Mavericks: Using the power button, holding the key for 1.5 seconds brings up the old Shut Down dialog, and holding for 5 seconds will shut down unconditionally. Holding control while pressing the power key will also bring up the Shut Down dialog.

Is there any way to restore the old, pre-Mavericks behavior as a preference? I'm used to using the power key to get the Shut Down dialog and seem to not be able to retrain myself particularly effectively.


Solution 1:

The file to change would be /Library/Preferences/SystemConfiguration/com.apple.PowerManagement.plist (cf this AD post)

In Lion/Mountain Lion we had a key Power Button. Unfortunately it's not recognized anymore. I'm pessimistic about restoring this behaviour.

Solution 2:

Since Mac OS 10.9.2 you can go back to something close to the pre-Mavericks behavior easily.

Type in terminal:
defaults write com.apple.loginwindow PowerButtonSleepsSystem -bool no

It's not exactly the same, since you still need to press the button for 1 sec. But if you press the button accidentally, the shut down dialog is not going to appear.

Note: if you want to go back to the Mavericks behavior, juste change no to yes.

Solution 3:

According to the following article, you can: http://binchewer.org/blog/index.php?id=1