I thought you could take care of turning off suspend when the laptop lid is shut under GNOME 3 by using GNOME Tweak Tool. That doesn't work.
Automatic suspend when the lid is closed doesn't work for me because suspend/resume doesn't function on my HP hardware, and I'd like to close the damn lid every once in awhile without having to do a hard boot afterward.
It's the little things.
In a terminal:
Once you're in
logind.conf, uncomment (i.e. remove the
#) on this line:
Then change "suspend" to "lock"
It should now read like this:
Save and close the
Once you reboot, closing the lid should lock the screen and not suspend the laptop.
Note: Xfce doesn't suffer from the same inability as GNOME 3 to control what happens when you close the laptop lid.
Alternate instructions if you want to use vi and sudo:
Open a terminal and type:
$ sudo vi /etc/systemd/logind.conf
Change this line:
to this (remove
Save and close the file in vi, then reboot.