From b953d2227e2b1125fde493dbed6da5567e6c6c81 Mon Sep 17 00:00:00 2001 From: holly sparkles Date: Fri, 26 Jan 2024 09:30:36 +0100 Subject: [PATCH] fix: missing repos prompting for login credentials --- src/main.rs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/main.rs b/src/main.rs index a0b2679..743c60f 100644 --- a/src/main.rs +++ b/src/main.rs @@ -50,15 +50,17 @@ async fn do_sync_task(args: CliArgs) { .stdout; if !refs_tag.is_empty() { - let status = Command::new("git") + let output = Command::new("git") + .env("GIT_TERMINAL_PROMPT", "0") .arg("--git-dir") .arg(dir.clone().into_path()) .arg("fetch") .arg("--all") - .status() + .output() .await .expect("Unable to fetch repository"); - if !status.success() { + + if !output.status.success() { error!("Failed to update repository {:?}", dir.path()) } } -- libgit2 1.7.2