pub trait CmdPipe {
fn pipe(&mut self, piped_command: &mut Command) -> Result<Output, Error>;
fn pipe_to_file(
&mut self,
piped_command: &mut Command,
file: File
) -> Result<(), Error>;
}Required Methods
Pipe stdout of self to stdin of piped_command
Errors
command.pipe(cmd) can result in std::io::Error
- when
spawnorwaitfail - when there is an issue with the stdout / stdin pipe (std::io::ErrorKind::BrokenPipe)
Pipe stdout of self to stdin of piped_command,
and pipe stdout of piped_command to file
Errors
command.pipe_to_file(cmd, file) can result in std::io::Error
- when
spawnorwaitfail - when there is an issue with the stdout / stdin pipe (std::io::ErrorKind::BrokenPipe)