Score:1

Make LidSwitch suspend *with* external monitor connected in 22.04

mx flag

There are lots of confusing discussions out there related to these settings in logind.conf

HandleLidSwitch
HandleLidSwitchExternalPower
HandleLidSwitchDocked
LidSwitchIgnoreInhibited

Most people seem to want to keep their laptops running with the lid closed when connected to an external monitor and this is now the default behavior in Ubuntu 22.04

I want the opposite, and that now seems to be impossible.
The clearest explanation I have found of how its intended to work is from Poettering himself here

My situation in short:
HandleLidSwitch*=suspend
LidSwitchIgnoreInhibited=true

But gsd-power is blocking handle-lid-switch when a monitor is connected (shown by:systemd-inhibit --list --mode=block), and LidSwitchIgnoreInhibited=true has no effect since this is a "low level inhibitor".

Additionally IgnoreLid=true in UPower.conf does not stop gsd-power from taking the lock and this is now possibly "as designed"

I read a suggestion somewhere that dbus could possibly be used to block upower from taking this lock, but I can find no further details of how this could be done.

All in all I would have thought this would be a quite common and reasonable behavior to want from a laptop, but now I'm stuck sideways way down this rabbit hole and I could really use some help getting out!

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.