#!../expect -f
#Name: noidle
#Description: expect script to run a shell which avoids being "autologged out"
#        by sending a <space><delete> every hour if no other I/O has occurred.
#Author: Don Libes, December 30, 1991

set timeout 3600
log_user 0
system stty -echo raw
spawn $env(SHELL)
expect	{
	timeout {send " \177"; continue -expect}
	-re .+ {send_user $expect_out(buffer); continue -expect}
	-i $user_spawn_id -re .+ {send $expect_out(buffer); continue -expect}
}
system stty echo -raw
