aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorveetaha <[email protected]>2020-03-22 10:01:49 +0000
committerveetaha <[email protected]>2020-03-22 10:01:49 +0000
commit8be28a2d4f1fa1593bab81e32e465dba35b99448 (patch)
treed8fb72ae7c0d7d67f7cd865203654672931322a2
parent788b29d343a3f4af6658e385621f1d1451d529e2 (diff)
ra_cargo_watch: log exit code too
-rw-r--r--crates/ra_cargo_watch/src/lib.rs6
1 files changed, 5 insertions, 1 deletions
diff --git a/crates/ra_cargo_watch/src/lib.rs b/crates/ra_cargo_watch/src/lib.rs
index 362d32010..7c525c430 100644
--- a/crates/ra_cargo_watch/src/lib.rs
+++ b/crates/ra_cargo_watch/src/lib.rs
@@ -318,7 +318,11 @@ pub fn run_cargo(
318 Ok(exit_code) if !exit_code.success() && !read_at_least_one_message => { 318 Ok(exit_code) if !exit_code.success() && !read_at_least_one_message => {
319 // FIXME: Read the stderr to display the reason, see `read2()` reference in PR comment: 319 // FIXME: Read the stderr to display the reason, see `read2()` reference in PR comment:
320 // https://github.com/rust-analyzer/rust-analyzer/pull/3632#discussion_r395605298 320 // https://github.com/rust-analyzer/rust-analyzer/pull/3632#discussion_r395605298
321 format!("the command produced no valid metadata: cargo {}", args.join(" ")) 321 format!(
322 "the command produced no valid metadata (exit code: {:?}): cargo {}",
323 exit_code,
324 args.join(" ")
325 )
322 } 326 }
323 Err(err) => format!("io error: {:?}", err), 327 Err(err) => format!("io error: {:?}", err),
324 Ok(_) => return Ok(()), 328 Ok(_) => return Ok(()),