On 12/09/2018 19.44, Doug wrote:
On 09/12/2018 04:49 PM, Carlos E. R. wrote:
On 12/09/2018 13.29, Per Jessen wrote: /snip/
Hi,
Somebody is asking an interesting question on usenet, and I'll ask it here in his stead.
He needs a "dead man button" application or script. If someone press the button, nothing is done. If not pressed for, say, 10 hours, send an email. Maybe send another periodically to confirm it is running.
Does somebody know of one such?
Not off hand, but it shouldn't be hard to do with a shell script. There are calls that can open a message on the screen etc.. Then wait for a response and loop as appropriate. Sure, I can code it myself, but he can't, and I wondered if it exists already. There is probably a website that offers that.
I'll tell him, thanks. But he wants faster activation, like 10 hours.
I didn't see the original of this thread,
You have it in the quotes at the start of your email ;-)
but whoever said 10 hours is more reasonable. The suggested website shows 30 DAYS to start with! My body would be eaten by my dog and the dog would have starved way before that! Maybe 24 to 36 hours would be a reasonable time period. Should be choosable. Should be easily reset or paused if a holiday or vacation should be in the schedule. If someone writes a script to do that, it should contain email addresses and a place for such messages. Hopefully would be usable on any Linux system, not dependent on a specific one.
Yes, 10 hours to send help. In Spain, on some cities you can get the social workers to call old people daily.
Please send me the program if you write one!
Doug--quite old!>
On usenet, this has been suggested: #!/bin/sh # How long the friend has before the message times out, in seconds TIMEOUT=36000 # The email address(es) to send a notice to EMAIL=email@example.com otheremail@somewhere.else if xmessage -buttons "Yes I am:1,I need help:0" \ -default "I need help" \ -timeout $TIMEOUT -nearmouse "Are you well?" then echo "Your friend failed to confirm his health at $(date)" | mailx -s "Your friend requires help" $EMAIL xmessage -timeout 30 -nearmouse "I have sent an alert message to $EMAIL" fi # END of script -- Cheers / Saludos, Carlos E. R. (from openSUSE 15.0 (Legolas)) -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org