diff options
Diffstat (limited to 'bin/extra')
| -rwxr-xr-x | bin/extra/saveself | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/bin/extra/saveself b/bin/extra/saveself index 8906a5f..90eba98 100755 --- a/bin/extra/saveself +++ b/bin/extra/saveself @@ -17,20 +17,15 @@ PrevCapacity="$(GetBatteryCapacity)" while true do - sleep 5 Capacity="$(GetBatteryCapacity)" if [ "$Capacity" -lt "$PrevCapacity" ] then if [ "$Capacity" -le "$Threshold" ] then - setsid slock HostName="$(hostname)" if [ "$HostName" = "spring" ] then - doas /usr/sbin/zzz -Z - elif [ "$HostName" = "winter" ] - then - systemctl hibernate + setsid doas /usr/sbin/zzz -Z fi fi PrevCapacity="$Capacity" |
