Force macbook to sleep when lid closed and external monitor connected in Lion
I know you have heard this before, but is there any app/hack that makes the computer behave like Snow Leopard when closing the lid?
I don't want to hear about this being a duplicate question, as I want a solution not an explanation.
Only post here if you have a solution that makes the macbook behave like in Snow Leopard when closing the lid.
Solution 1:
This worked in 10.7 and 10.8 with my MacBook Air:
sudo nvram boot-args=iog=0x0
After restarting, it should restore the pre-10.7 behavior:
- Closing the lid puts a laptop to sleep even when it is connected to an external display
- If you then wake the laptop up and open the lid, the internal display doesn't turn on
To undo it, run sudo nvram -d boot-args
or hold ⌥⌘PR on startup.
Solution 2:
In previous versions of OS X, you would go to ~/Library/Preferences/SystemConfiguration to find a file called com.apple.PowerManagement.plist. In that file you would find ways to tweak things like the old "clamshell" mode. I have not looked in Lion yet to see if this still exists, but if the file is still there, you may want to take a look at what it allows you to control. Hope this helps.
Solution 3:
I had this issue too, and came up with this script that monitors your lid state and puts the machine to sleep when lid is closed: https://github.com/pirj/noclamshell