I use the i3 window manager and have
set $Locker i3lock --color=000000 && sleep 1
exec --no-startup-id xautolock -time 5 -locker "$Locker"
in its config file, so that it locks after 5 minutes.
The problem is that the 5 minutes timer counts down even when I'm whatching a video, which I definitely don't like. (Btw, I usually watch movies with mplayer
, but sometimes I go on streaming websites as well, using qutebrowser
.) On the contrary, I'd like to prevent xautolock
s action in such situations.
One possible solution I was thinking of is changing the second line to
exec --no-startup-id myscript -time 5 -locker "$Locker"
where myscript
is a bash/whatever script/program passing all options to xautolock
only if I'm not watching some video stuff. But I don't know what to check with this hypothetical script.