This commit is contained in:
Timerix22 2024-01-07 01:18:58 +06:00
parent 7aaf2acab4
commit 34f298c43b

View File

@ -83,7 +83,7 @@ static class Server
logger.LogWarn(nameof(CheckUpdates), "program update found, restarting...");
string exeFile = relativeFilePath.Str;
string exeFileNew = exeFile + "_new";
File.Move(relativeFilePath, exeFileNew, true);
File.Move(updatedFilePath, exeFileNew, true);
if(Environment.OSVersion.Platform == PlatformID.Win32NT)
Process.Start("cmd",$"/c move {exeFileNew} {exeFile} && {exeFile}");
else