From 26e424a4aa2c4efdedbd68e119728400c99a017b Mon Sep 17 00:00:00 2001 From: Damien Cassou Date: Fri, 19 Jun 2015 11:16:32 +0200 Subject: Explanation to desktopManagerHandlesLidAndPower With this patch, systemd-inhibit outputs a descriptive message when desktopManagerHandlesLidAndPower=true (the default). Before the patch: $ systemd-inhibit Who: /nix/store/[...]-xsession [...] (UID 1000/cassou, PID 18561/systemd-inhibit) What: handle-power-key:handle-lid-switch Why: Unknown reason Mode: block After the patch: $ systemd-inhibit Who: /nix/store/[...]-xsession [...] (UID 1000/cassou, PID 18561/systemd-inhibit) What: handle-power-key:handle-lid-switch Why: See NixOS configuration option 'services.xserver.displayManager.desktopManagerHandlesLidAndPower' for more information. Mode: block --- nixos/modules/services/x11/display-managers/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'nixos') diff --git a/nixos/modules/services/x11/display-managers/default.nix b/nixos/modules/services/x11/display-managers/default.nix index c5012dbb5e30..70a4303d8973 100644 --- a/nixos/modules/services/x11/display-managers/default.nix +++ b/nixos/modules/services/x11/display-managers/default.nix @@ -56,7 +56,7 @@ let if [ -z "$_INHIBITION_LOCK_TAKEN" ]; then export _INHIBITION_LOCK_TAKEN=1 if ! ${config.systemd.package}/bin/loginctl show-session $XDG_SESSION_ID | grep -q '^RemoteHost='; then - exec ${config.systemd.package}/bin/systemd-inhibit --what=handle-lid-switch:handle-power-key "$0" "$sessionType" + exec ${config.systemd.package}/bin/systemd-inhibit --what=handle-lid-switch:handle-power-key --why="See NixOS configuration option 'services.xserver.displayManager.desktopManagerHandlesLidAndPower' for more information." "$0" "$sessionType" fi fi -- cgit 1.4.1