[comp.unix.xenix] Wanted: Screen saver for SCO Xenix 2.2.3

amos@placer1.COM (Kevin Amos) (08/24/89)

Could someone please send me a screen saver program that
will run on SCO 286 Xenix 2.2.3.

Thanks

-- 
Kevin Amos
Placer Dome Inc.
Internet: amos@placer1.com  
uucp: {ubc-cs,uunet}van-bc!placer1!amos

chip@vector.Dallas.TX.US (Chip Rosenthal) (08/26/89)

In article <259@placer1.COM> amos@placer1.COM (Kevin Amos) writes:
>Could someone please send me a screen saver program that
>will run on SCO 286 Xenix 2.2.3.

This will clear console screens idle for more than 15 mins.

    :
    who -u | awk '{
	tty=$2				# basename of tty
	idle=$6				# time idle in "hh:mm"
	if ( tty !~ /^tty[01][0-9]$/ || idle == "." )
	    next			# skip non-console & non-idle terms
	n = split(idle,x,":")
	if ( x[1] * 60 + x[2] > 15 )	# print tty if idle > 15 mins
	    print tty
    }' | while read tty ; do echo "\f" > /dev/$tty ; done

Suitable for running from cron.  Also note that writing to the console
screen will reset that screen's idle time counter.  Also note that this
might need to be run as root if permissions require (e.g. "mssg n" was
run on one of the screens).
-- 
Chip Rosenthal / chip@vector.Dallas.TX.US / Dallas Semiconductor / 214-450-5337
"I wish you'd put that starvation box down and go to bed" - Albert Collins' Mom