For Scala Bot, I need to capture stdout and stderror, as well as the program's exit code. We can look at how SBT and tut do this, as reference.