Open NoNameJe opened 1 year ago
Hey there - thanks for this. I may take some time to see if I can detect if the disk is MBR or GPT before building the diskpart command script to avoid having to convert twice.
-CorpNewt
If you do a list disk in diskpart, it shows which ones are gpt vs mbr in its own column, you could scrape that probably, but I'm sure there is a more programmatic way to ask the system
Please change code MakeInstall.py 270 line
print("Using GPT...") print(self.hfs_id) dp_script = "\n".join([ "select disk {}".format(disk.get("index",-1)), "clean", "convert mbr", #please first convert to another "convert gpt", # sencondy convert to gpt Because this will not stop on error "create partition primary size=200", "format quick fs=fat32 label='BOOT'", "create partition primary noerr", #without id=xxx "select partition 2", "set id={} override noerr".format(self.hfs_id) # set id ])
If the disk is already gpt , "convert gpt" will return error,so first convert to mbr