Skip to content

Commit f868ea8

Browse files
committed
Windows improvements and update extlinux.cfg
1. Hide command wind when multibootusb is launched 2. Update extlinux.cfg to match with updated syslinux.cfg
1 parent 5809fb7 commit f868ea8

File tree

4 files changed

+9
-3
lines changed

4 files changed

+9
-3
lines changed

build_pkg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ class pkg():
157157
else:
158158
# subprocess.call('python ' + pyinstaller_path + ' --upx-dir C:\\upx multibootusb.spec', shell=True) == 0 and \
159159
# os.path.exists(os.path.join("dist", 'multibootusb-' + self.version + ".exe")):
160-
if subprocess.call('python ' + pyinstaller_path + ' --onefile onefile-multibootusb.spec', shell=True) == 0 and \
160+
if subprocess.call('python ' + pyinstaller_path + ' --uac-admin --onefile onefile-multibootusb.spec', shell=True) == 0 and \
161161
os.path.exists(os.path.join("dist", 'multibootusb-' + self.version + ".exe")):
162162
shutil.copy2(os.path.join("dist", 'multibootusb-' + self.version + ".exe"),
163163
os.path.join(self.release_upload_dir, "Windows"))

data/version.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8.9.0
1+
9.0.0

scripts/update_cfg_file.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -409,6 +409,9 @@ def update_mbusb_cfg_file(iso_link, usb_uuid, usb_mount, distro):
409409

410410
config_file.write("#end " + iso_basename(iso_link) + "\n")
411411
config_file.close()
412+
# Update extlinux.cfg file by copying updated syslinux.cfg
413+
shutil.copy(os.path.join(usb_mount, 'multibootusb', 'syslinux.cfg'),
414+
os.path.join(usb_mount, 'multibootusb', 'extlinux.cfg'))
412415

413416

414417
def kaspersky_config(distro):

scripts/usb.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -361,9 +361,12 @@ def gpt_device(dev_name):
361361
:return: True if GPT else False
362362
"""
363363
if platform.system() == 'Windows':
364+
startupinfo = subprocess.STARTUPINFO()
365+
startupinfo.dwFlags |= subprocess.STARTF_USESHOWWINDOW
364366
diskpart_cmd = 'wmic partition get name, type'
365367
dev_no = get_physical_disk_number(dev_name)
366-
cmd_out = subprocess.check_output(diskpart_cmd)
368+
cmd_out = subprocess.check_output(diskpart_cmd, subprocess.SW_HIDE, startupinfo=startupinfo)
369+
gen.log(cmd_out)
367370
cmd_spt = cmd_out.split(b'\r')
368371
for line in cmd_spt:
369372
line = line.decode('utf-8')

0 commit comments

Comments
 (0)