aboutsummaryrefslogtreecommitdiffstats
path: root/bin/adjust_dpms
diff options
context:
space:
mode:
Diffstat (limited to 'bin/adjust_dpms')
-rwxr-xr-xbin/adjust_dpms11
1 files changed, 8 insertions, 3 deletions
diff --git a/bin/adjust_dpms b/bin/adjust_dpms
index 758541e..76d2bd5 100755
--- a/bin/adjust_dpms
+++ b/bin/adjust_dpms
@@ -23,7 +23,7 @@ do
re='^[0-9]+$'
if [[ $pid =~ $re ]]; then
echo "$i running ($pid)"
- $blankoff=1
+ blankoff=1
fi
done
@@ -34,7 +34,7 @@ do
re='^[0-9]+$'
if [[ $pid =~ $re ]]; then
echo "$i running ($pid)"
- $blankoff=1
+ blankoff=1
fi
done
@@ -43,7 +43,12 @@ if [ $blankoff -gt 0 ]; then
echo "$blankoff"
echo "Some program requires screensaver to be off."
xset s off
+# else set 360 seconds as blank time
else
- xset s on
+ xsetq=$(xset q|grep timeout|awk '{print $2}')
+ if [ $xsetq -eq 0 ];then
+# xset s 360 360
+ xset s on
+ fi
fi