diff options
| author | Vasil Zlatanov <v@skozl.com> | 2017-04-19 21:39:12 +0200 |
|---|---|---|
| committer | Vasil Zlatanov <v@skozl.com> | 2017-04-19 21:39:12 +0200 |
| commit | 38535167b49fe25764471554dcedefde5cc94b83 (patch) | |
| tree | 85994b04bc53a4fdab9af3593ce7a2e232178aef /Panel/lemonbar/batterymon | |
| parent | 599356ac95e5188bc16470a3d12b64af8811f9f8 (diff) | |
| download | dotfiles-38535167b49fe25764471554dcedefde5cc94b83.tar.gz dotfiles-38535167b49fe25764471554dcedefde5cc94b83.tar.bz2 dotfiles-38535167b49fe25764471554dcedefde5cc94b83.zip | |
massive new latpop updates
Diffstat (limited to 'Panel/lemonbar/batterymon')
| -rwxr-xr-x | Panel/lemonbar/batterymon | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/Panel/lemonbar/batterymon b/Panel/lemonbar/batterymon index 27ea7a6..9d8c74d 100755 --- a/Panel/lemonbar/batterymon +++ b/Panel/lemonbar/batterymon @@ -1,13 +1,14 @@ #!/bin/sh while true;do -if [ `battery -f '%i'` -lt 4 ] && ! [ -z ~/.dontshut ]; then -touch ~/.dontshut -zenity --question --title "Battery" --text "Battery if pretty fucking low, go to sleep?" -if [ $? -ne 1 ];then -pm-suspend -fi -else -rm ~/.dontshut -fi + if [ `battery -f '%i'` -lt 4 ] && ! [ -z ~/.dontshut ]; then + touch ~/.dontshut + zenity --question --title "Battery" --text "Battery if pretty fucking low, go to sleep?" + if [ $? -ne 1 ];then + pm-suspend + fi + else + if [ -z ~/.dontshut ] + rm ~/.dontshut + fi sleep 180; done |
