help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-bash] upstart sh script, wait 60 seconds, abort on key press


From: proper
Subject: [Help-bash] upstart sh script, wait 60 seconds, abort on key press
Date: Fri, 06 Jul 2012 16:39:58 +0200

Hello everyone,

Question about an upstart sh script:
http://www.codewhirl.com/2011/10/ubuntu-11-10-waiting-up-to-60-more-seconds-for-network-configuration/

The hardcoded sleep 60 is awful. I'd like to write a patch adding a feature to 
allow aborting the wait.

Is there any sh command to wait and at the same time break if ESC, ctrl + c or 
any other key is pressed?

I tried with 'read', but while booting (upstart) does not seem not to use the 
console (command ignored).

Cheers,
proper

______________________________________________________
powered by Secure-Mail.biz - anonymous and secure e-mail accounts.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]