Added elogind config for lid: suspend and powerbutton: hibernate
This commit is contained in:
parent
5c455d9b4b
commit
3f15867d1c
2 changed files with 55 additions and 0 deletions
45
etc/elogind/logind.conf
Normal file
45
etc/elogind/logind.conf
Normal file
|
@ -0,0 +1,45 @@
|
|||
# This file is part of elogind.
|
||||
#
|
||||
# elogind is free software; you can redistribute it and/or modify it under the
|
||||
# terms of the GNU Lesser General Public License as published by the Free
|
||||
# Software Foundation; either version 2.1 of the License, or (at your option)
|
||||
# any later version.
|
||||
#
|
||||
# Entries in this file show the compile time defaults. Local configuration
|
||||
# should be created by either modifying this file, or by creating "drop-ins" in
|
||||
# the logind.conf.d/ subdirectory. The latter is generally recommended.
|
||||
# Defaults can be restored by simply deleting this file and all drop-ins.
|
||||
#
|
||||
# See logind.conf(5) for details.
|
||||
|
||||
[Login]
|
||||
#KillUserProcesses=no
|
||||
#KillOnlyUsers=
|
||||
#KillExcludeUsers=root
|
||||
#InhibitDelayMaxSec=5
|
||||
#UserStopDelaySec=10
|
||||
HandlePowerKey=hibernate
|
||||
#HandlePowerKeyLongPress=ignore
|
||||
#HandleRebootKey=reboot
|
||||
#HandleRebootKeyLongPress=poweroff
|
||||
#HandleSuspendKey=suspend
|
||||
#HandleSuspendKeyLongPress=hibernate
|
||||
#HandleHibernateKey=hibernate
|
||||
#HandleHibernateKeyLongPress=ignore
|
||||
HandleLidSwitch=suspend
|
||||
#HandleLidSwitchExternalPower=suspend
|
||||
#HandleLidSwitchDocked=ignore
|
||||
#PowerKeyIgnoreInhibited=no
|
||||
#SuspendKeyIgnoreInhibited=no
|
||||
#HibernateKeyIgnoreInhibited=no
|
||||
#LidSwitchIgnoreInhibited=yes
|
||||
#RebootKeyIgnoreInhibited=no
|
||||
#HoldoffTimeoutSec=30s
|
||||
#IdleAction=ignore
|
||||
#IdleActionSec=30min
|
||||
#RuntimeDirectorySize=10%
|
||||
#RuntimeDirectoryInodesMax=
|
||||
#RemoveIPC=yes
|
||||
#InhibitorsMax=8192
|
||||
#SessionsMax=8192
|
||||
#StopIdleSessionSec=infinity
|
10
lib64/elogind/system-sleep/lock.sh
Executable file
10
lib64/elogind/system-sleep/lock.sh
Executable file
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
case $1/$2 in
|
||||
pre/*)
|
||||
# Put here any commands expected to be run when suspending or hibernating.
|
||||
qdbus6 --system org.freedesktop.DisplayManager /org/freedesktop/DisplayManager/Seat0 org.freedesktop.DisplayManager.Seat.SwitchToGreeter
|
||||
;;
|
||||
post/*)
|
||||
# Put here any commands expected to be run when resuming from suspension or thawing from hibernation.
|
||||
;;
|
||||
esac
|
Loading…
Add table
Reference in a new issue