From af6e91b51659d19650c603fda42d6ce2894ba90a Mon Sep 17 00:00:00 2001 From: Federico Terzi Date: Thu, 4 Nov 2021 22:09:13 +0100 Subject: [PATCH] fix(core): add delay in restart command to mitigate #839 --- espanso/src/cli/service/mod.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/espanso/src/cli/service/mod.rs b/espanso/src/cli/service/mod.rs index c5ba8f1..6cf18fa 100644 --- a/espanso/src/cli/service/mod.rs +++ b/espanso/src/cli/service/mod.rs @@ -101,6 +101,7 @@ fn service_main(args: CliModuleArgs) -> i32 { return status_main(&paths); } else if let Some(sub_args) = cli_args.subcommand_matches("restart") { stop_main(&paths); + std::thread::sleep(std::time::Duration::from_millis(300)); return start_main(&paths, &paths_overrides, sub_args); }