On Sun, Feb 18, 2018 at 10:39:10PM +0100, Josip Rodin wrote: > On Sun, Feb 18, 2018 at 07:21:52PM +0100, Josip Rodin wrote: > > The xscreensaver package should probably document some of these options, > > provide examples, and add some package relationships to indicate what should > > be done... laptops suspending isn't really a niche use case these days. > > Fun fact: the latter method I found is already obsolete... the systemd way > is to put something in /lib/systemd/system-sleep/, yet the systemd-sleep > manual page says: > > Note that scripts or binaries dropped in /lib/systemd/system-sleep/ are > intended for local use only and should be considered hacks. If > applications want to be notified of system suspend/hibernation and > resume, there are much nicer interfaces available. > > It proceeds not to actually mention any one of those nicer interfaces.
Found it after some more googling, at https://wiki.freedesktop.org/www/Software/systemd/inhibit/ A screen lock tool wants to bring up the screen lock right before suspend, and delay the suspend until that's complete. Applications which want to make use of the inhibition logic shall take an inhibitor lock via the logind D-Bus API. -- 2. That which causes joy or happiness.