From 4fa90bfc40841fc35f3b17332126c585cf494356 Mon Sep 17 00:00:00 2001 From: Stephan Dilly Date: Fri, 27 Mar 2020 22:46:25 +0100 Subject: [PATCH] diagnose win test error --- asyncgit/src/sync/reset.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/asyncgit/src/sync/reset.rs b/asyncgit/src/sync/reset.rs index dd353e87..33a281ae 100644 --- a/asyncgit/src/sync/reset.rs +++ b/asyncgit/src/sync/reset.rs @@ -51,7 +51,13 @@ pub fn index_reset_at(repo_path: &str, path: &Path) -> bool { .output() }; - output.is_ok() + if let Ok(out) = output { + dbg!(String::from_utf8(out.stderr.clone()).unwrap()); + String::from_utf8(out.stderr).unwrap() + == "Updated 1 path from the index\n".to_string() + } else { + false + } //------------------------------------ //TODO: why is this broken with libgit2 ???