Surpress explicit news printing when paru is used (#623)

This commit is contained in:
Heiko Carrasco
2021-02-10 17:32:15 +01:00
committed by GitHub
parent 729b5b6cb4
commit 8b7ff6a042

View File

@@ -156,14 +156,17 @@ fn upgrade_arch_linux(ctx: &ExecutionContext) -> Result<()> {
}; };
debug!("Running Arch update with path: {:?}", path); debug!("Running Arch update with path: {:?}", path);
if let Some(yay) = which("yay").or_else(|| which("paru")) { let yay = which("yay");
if let Some(yay) = &yay {
run_type run_type
.execute(&yay) .execute(&yay)
.arg("-Pw") .arg("-Pw")
.spawn() .spawn()
.and_then(|mut p| p.wait()) .and_then(|mut p| p.wait())
.ok(); .ok();
}
if let Some(yay) = yay.or_else(|| which("paru")) {
let mut command = run_type.execute(&yay); let mut command = run_type.execute(&yay);
command command