Reputation: 96266
I want to create multiple processes (each with cmd + arguments).
I need the pid
of the created process so I can kill it if needed.
I also want to be able to read its output (line-by-line) in a non-blocking way (otherwise I have to create threads which I would like to avoid). Feeding its standard input is a bonus.
What's the best way to do this in ruby?
Upvotes: 2
Views: 292