mirror of
https://github.com/ytdl-org/youtube-dl
synced 2025-03-17 21:42:22 +09:00
Run 'execute replacing bat file' using subprocess.Popen in order to prevent cmd window popup while running the 'bat' file.
This fix is relevant to the upgrade feature under windoes OS.
This commit is contained in:
parent
b00ca882a4
commit
e7980bf43b
@ -1,6 +1,7 @@
|
||||
import json
|
||||
import traceback
|
||||
import hashlib
|
||||
import subprocess
|
||||
from zipimport import zipimporter
|
||||
|
||||
from .utils import *
|
||||
@ -125,7 +126,7 @@ del "%s"
|
||||
\n""" %(exe, exe, bat))
|
||||
b.close()
|
||||
|
||||
os.startfile(bat)
|
||||
subprocess.Popen(bat, shell=True)
|
||||
except (IOError, OSError) as err:
|
||||
if verbose: to_screen(compat_str(traceback.format_exc()))
|
||||
to_screen(u'ERROR: unable to overwrite current version')
|
||||
|
Loading…
Reference in New Issue
Block a user