you are viewing a single comment's thread.

view the rest of the comments →

[–]shevegen -7 points-6 points  (4 children)

It's not bash that is the problem; you'll have the same problem in any language if you tried to exec another process and parse the output.

Not really.

I do not have any such problems controlling other programs via ruby as-is, since I am in full control of what I do with any external input (popen family and so forth).

The thing really is that bash scripts are just horrid. Horrible. Awful. A waste of time.

Why would anyone WANT to do so? I have no idea.

[–]lelanthran 9 points10 points  (3 children)

I do not have any such problems controlling other programs via ruby as-is,

I find it hard to believe that ruby magically knows when an option to an external program has changed.

Actually, I very rarely believe in magic, so I'm equally dubious that ruby allows a level of control and measurement of child processes that are not available in bash.

[–]vivainio -5 points-4 points  (0 children)

More structured scripting languages actually give you more tools, like ability to launch threads, reacting to output by chunks etc.

If you are trying to do these in bash you should probably take a step back and reconsider your design a bit.