🎨 Improve updater on Windows

This commit is contained in:
Daniel 2023-06-28 09:29:49 +08:00
parent ca15c14bdb
commit 09f4954f96
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
2 changed files with 2 additions and 2 deletions

View file

@ -41,7 +41,7 @@ func execNewVerInstallPkg(newVerInstallPkgPath string) {
logging.LogInfof("installing the new version [%s]", newVerInstallPkgPath)
var cmd *exec.Cmd
if gulu.OS.IsWindows() {
cmd = exec.Command(newVerInstallPkgPath)
cmd = exec.Command("cmd.exe", "/C", "start", newVerInstallPkgPath)
} else if gulu.OS.IsDarwin() {
exec.Command("chmod", "+x", newVerInstallPkgPath).CombinedOutput()
cmd = exec.Command("open", newVerInstallPkgPath)