local locked
export DISPLAY=:0
locked=false
- if lock_info=$(xscreensaver-command -timer); then
+ if lock_info=$(xscreensaver-command -time); then
if [[ $lock_info != *non-blanked* ]]; then
locked=true
fi
if $locked && (( mdiff < 6 || mdiff > 21 )); then
case $(pactl get-sink-mute @DEFAULT_SINK@ | awk '{print $2}') in
no)
+ # for log purposes
+ echo unmuted
pactl set-sink-mute @DEFAULT_SINK@ true
;;
esac
if ! $locked && (( mdiff > 6 || mdiff < 12 )) && [[ ! -e /tmp/ianknap ]]; then
case $(pactl get-sink-mute @DEFAULT_SINK@ | awk '{print $2}') in
yes)
+ # for log purposes
+ echo muted
pactl set-sink-mute @DEFAULT_SINK@ false
;;
esac