|
|
@ -29,7 +29,7 @@ pub fn is_success(res: Result<Output, impl Error + 'static>) -> Result<Output, B |
|
|
|
check_success(res?)
|
|
|
|
}
|
|
|
|
|
|
|
|
pub fn get_output(output: Output) -> Result<Vec<u8>, Box<dyn Error>> {
|
|
|
|
pub fn get_stdout(output: Output) -> Result<Vec<u8>, Box<dyn Error>> {
|
|
|
|
Ok(check_success(output)?.stdout)
|
|
|
|
}
|
|
|
|
|
|
|
@ -55,7 +55,7 @@ pub trait CommandRunner { |
|
|
|
args: &'a [&'a OsStr],
|
|
|
|
) -> Result<Vec<u8>, Box<dyn Error>> {
|
|
|
|
let output = self.run_with_args(program, args).await?;
|
|
|
|
get_output(output)
|
|
|
|
get_stdout(output)
|
|
|
|
}
|
|
|
|
async fn run_successfully<'a>(
|
|
|
|
&self,
|
|
|
|