With Cygwin, I tried to use “timeout” to make my script sleep for a few seconds.
But even when I did it according to its syntax it always asks me to try --help, meaning I gave the wrong forms.
Here are the things I’ve tried
timeout 5
timeout 5s
timeout 5.0s
timeout 5.
None of which worked.
Any ideas?!
I don’t think
timeoutdoes what you think it does. From the man page:You need to give it that command. Here’s a simple example:
As you can see, only 5 seconds elapsed even though I ran
sleep 10. That’s because it timed out after 5 seconds and thetimeoutcommand killed it.