Explorar o código

correct re-laucnh after update

olivier.massot %!s(int64=8) %!d(string=hai) anos
pai
achega
2a0553dad8
Modificáronse 2 ficheiros con 2 adicións e 2 borrados
  1. BIN=BIN
      setup-hello_world.exe
  2. 2 2
      updater.py

BIN=BIN
setup-hello_world.exe


+ 2 - 2
updater.py

@@ -63,9 +63,9 @@ def update():
                 handle.write(chunk)
 
     # Run the installer and restart the start command
-    args = "/SILENT && {}".format(" ".join(sys.argv[:]))
+    args = "/c {} /SILENT & {} {}".format(TMP_SETUPFILE, sys.executable, " ".join(sys.argv[:]))
 
-    Popen([TMP_SETUPFILE, args], shell=True)
+    Popen(["cmd.exe", args], shell=True)
 
     # An UpdateNeeded exception is raised so the script exit before being restarted by subprocess
     raise UpdateNeeded()