MCPcopy Create free account
hub / github.com/NativeScript/SimDeck / bail_with_output

Function bail_with_output

packages/server/src/core_simulator.rs:62–75  ·  view source on GitHub ↗
(command: &str, output: Output)

Source from the content-addressed store, hash-verified

60}
61
62fn bail_with_output(command: &str, output: Output) -> anyhow::Result<Output> {
63 let stderr = String::from_utf8_lossy(&output.stderr).trim().to_owned();
64 let stdout = String::from_utf8_lossy(&output.stdout).trim().to_owned();
65 bail!(
66 "{command} failed: {}",
67 if !stderr.is_empty() {
68 stderr
69 } else if !stdout.is_empty() {
70 stdout
71 } else {
72 format!("exit status {}", output.status)
73 }
74 );
75}
76
77fn print_status(action: &str) {
78 println!(

Callers 2

stop_serviceFunction · 0.85
run_xcrunFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected