Detect that a child is waiting for input

unDEFER via Digitalmars-d digitalmars-d at puremagic.com
Wed Nov 23 07:54:30 PST 2016


On Tuesday, 22 November 2016 at 22:30:06 UTC, wobbles wrote:
> Easier said than done as there's no signal the child sends to 
> say "OK, I'm waiting now".
>
> You can use expect to do this, if you know what the output of 
> the child will be just before it's waiting for IO.
>
> This is the D lib I've written to do this:
> https://github.com/grogancolin/dexpect
>
> It's not wonderful or anything, but it works :)

Thank you, good decision. Maybe I will use the idea. But how to 
detect that "cat" (without arguments) waits input, if it nothing 
prints?


More information about the Digitalmars-d mailing list