From e6f11c354d9f23f860ba2d8f2c7e2acd22fc0be5 Mon Sep 17 00:00:00 2001 From: Kang Yu Date: Wed, 28 Aug 2024 15:52:01 -0700 Subject: [PATCH] #348, insufficient delay causes failure to upgrade --- .../SystrayShell/SystrayForm.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Ninjacrab.PersistentWindows.Solution/SystrayShell/SystrayForm.cs b/Ninjacrab.PersistentWindows.Solution/SystrayShell/SystrayForm.cs index dcb7130..588ad79 100644 --- a/Ninjacrab.PersistentWindows.Solution/SystrayShell/SystrayForm.cs +++ b/Ninjacrab.PersistentWindows.Solution/SystrayShell/SystrayForm.cs @@ -266,7 +266,7 @@ namespace PersistentWindows.SystrayShell upgradeDownloaded[latestVersion] = true; string batFile = Path.Combine(Program.AppdataFolder, $"pw_upgrade.bat"); - string content = "timeout /t 5 /nobreak > NUL"; + string content = "timeout /t 10 /nobreak > NUL"; content += $"\ncopy /Y \"{dst_dir}\\*.*\" \"{install_dir}\""; content += "\nstart \"\" /B \"" + Path.Combine(install_dir, Application.ProductName) + ".exe\" " + Program.CmdArgs; File.WriteAllText(batFile, content);