Linux - How to fold only when screensaver is on - RESOLVED

Moderators: Site Moderators, FAHC Science Team

Linux - How to fold only when screensaver is on - RESOLVED

Postby vince_lewis » Fri Jul 31, 2020 2:12 pm

Just FYI I am running Ubuntu Studio, and FAH version 7.5.1, and I'm using xscreensaver as my screen saver.

Some users (myself included) find the the fold when Idle on linux doesn't work - it never starts.

I've written a script that I run on startup that addresses this.

Code: Select all
#!/bin/bash
sleep 90
xhost +
DISPLAY=:0 xscreensaver-command -watch | while read -r line
do
# does the result of the last change in xscreensaver status start with BLANK (ie screensaver on) or UNBLANK (screensaver off) ?
if [[ $line == BLANK* ]]
then
FAHClient --send-unpause
else
FAHClient --send-pause
fi
done



Hopefully this is of use to some of you. Note I had to put this in the crontab for the logged on user, and NOT run it as sudo.
vince_lewis
 
Posts: 17
Joined: Sat Dec 10, 2016 12:43 am

Return to Discussions of General-FAH topics

Who is online

Users browsing this forum: No registered users and 4 guests

cron