#!/bin/bash mousescreenlockfile=/tmp/mousescreenlockfile if [ -f $mousescreenlockfile ]; then rm $mousescreenlockfile && killall mousescreenlock else touch $mousescreenlockfile sleep 5s while [ -f $mousescreenlockfile ] do # xdotool mousemove 1919 0; xscreensaver-command activate done fi