Say I invoke
some-stream() { while true; do openssl rand -hex 8; done }
some-stream | less +F
And hit Ctrl-C
then less will stop tailing, but if I hit F
to resume tailing then no more output will be generated. Presumably because the pipe was broken. Is there a way to prevent this from happening?
I guess one way would be to use mkfifo
, but suppose I only want to read from some-stream
lazily. Then what?