To retrieve piped input to my program I can use something like
ARGF.readlines

However, if there is no piped data, this will wait for input from the
terminal- how can I avoid this?

Thanks,
Greg Weber