Fixes
This commit is contained in:
@@ -12,6 +12,7 @@ case $1 in
|
||||
pre)
|
||||
logger -t "SmartSleep" "Das System wechselt in den Energiesparmodus"
|
||||
[ -n "$(pgrep smartsleepd)" ] || logger -t "SmartSleep" -p "user.warning" "Der Daemon läuft nicht!"
|
||||
pkill signal
|
||||
;;
|
||||
post)
|
||||
LID_STATUS="$( awk '{print $2}' < /proc/acpi/button/lid/LID0/state )" # open|closed
|
||||
|
||||
+13
-2
@@ -14,8 +14,19 @@ checkSleep() {
|
||||
fi
|
||||
}
|
||||
|
||||
trap 'checkSleep && systemctl suspend' USR1
|
||||
trap 'notify-send "SmartSleep" "Energiesparmodus beendet"; checkSleep' USR2
|
||||
suspendStart() {
|
||||
checkSleep && systemctl suspend
|
||||
}
|
||||
|
||||
suspendFinish() {
|
||||
notify-send "SmartSleep" "Energiesparmodus beendet"
|
||||
checkSleep
|
||||
#/opt/Signal/signal-desktop --no-sandbox &
|
||||
#sleep 3 && kdocker -w $(xwininfo -root -tree | grep Signal | tail -n1 | awk '{print $1}')
|
||||
}
|
||||
|
||||
trap 'suspendStart' USR1
|
||||
trap 'suspendFinish' USR2
|
||||
|
||||
while true; do
|
||||
sleep infinity &
|
||||
|
||||
Reference in New Issue
Block a user