3 ms·
It doesn't speed up. The sed program will wait forever for input, so it has no set speed. The helper bash script gives it input once a second. It uses the "re
by ars 16y ago
It doesn't speed up. The sed program will wait forever for input, so it has no set speed.
The helper bash script gives it input once a second.
It uses the "read" command to check for input from you, and it will wait 1 second. If it gets no input it sends the sed program an enter.
Unfortunately "read" can not have timeouts less than a second (it doesn't support fractions of a second).
If you want, you could replace "read" with a different program that accepts shorter timeouts. And presumably you could have the bash script slowly decrease the timeout.