From e76206817de1cb86ec431dcff7d4b04c8b7d36fc Mon Sep 17 00:00:00 2001 From: elkowar <5300871+elkowar@users.noreply.github.com> Date: Sun, 26 Mar 2023 13:10:35 +0200 Subject: [PATCH] Add timeout log to run_command --- crates/eww/src/widgets/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/eww/src/widgets/mod.rs b/crates/eww/src/widgets/mod.rs index d079169..e5e25b7 100644 --- a/crates/eww/src/widgets/mod.rs +++ b/crates/eww/src/widgets/mod.rs @@ -20,7 +20,7 @@ where std::thread::Builder::new() .name("command-execution-thread".to_string()) .spawn(move || { - log::debug!("Running command from widget: {}", cmd); + log::debug!("Running command from widget [timeout: {}ms]: {}", timeout.as_millis(), cmd); let child = Command::new("/bin/sh").arg("-c").arg(&cmd).spawn(); match child { Ok(mut child) => match child.wait_timeout(timeout) {