pub fn drain_pipe(reader: &PipeReader) -> Vec<u8>Expand description
Capture all output written to a pipe writer and return it as bytes.
This is a helper for the shell to capture command output for piping and command substitution. The writer should already be closed.