mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-06-20 22:20:53 +10:00
reroute_payloads.py: Remove unused import
This commit is contained in:
@@ -2,7 +2,6 @@
|
|||||||
# Implements a shadowfile to avoid direct writes to the dmg
|
# Implements a shadowfile to avoid direct writes to the dmg
|
||||||
# Copyright (C) 2022, Mykola Grymalyuk
|
# Copyright (C) 2022, Mykola Grymalyuk
|
||||||
|
|
||||||
import sys
|
|
||||||
import plistlib
|
import plistlib
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
import subprocess
|
import subprocess
|
||||||
@@ -17,7 +16,7 @@ class reroute_payloads:
|
|||||||
# Create a temp directory to mount the payloads.dmg
|
# Create a temp directory to mount the payloads.dmg
|
||||||
# Then reroute r/w to this new temp directory
|
# Then reroute r/w to this new temp directory
|
||||||
# Currently only applicable for GUI variant
|
# Currently only applicable for GUI variant
|
||||||
if self.constants.launcher_binary and self.constants.wxpython_variant is True and not self.constants.launcher_script:
|
if self.constants.wxpython_variant is True and not self.constants.launcher_script:
|
||||||
print("- Running in Binary GUI mode, switching to tmp directory")
|
print("- Running in Binary GUI mode, switching to tmp directory")
|
||||||
self.temp_dir = tempfile.TemporaryDirectory()
|
self.temp_dir = tempfile.TemporaryDirectory()
|
||||||
print(f"- New payloads location: {self.temp_dir.name}")
|
print(f"- New payloads location: {self.temp_dir.name}")
|
||||||
@@ -28,7 +27,8 @@ class reroute_payloads:
|
|||||||
[
|
[
|
||||||
"hdiutil", "attach", "-noverify", f"{self.constants.payload_path}.dmg",
|
"hdiutil", "attach", "-noverify", f"{self.constants.payload_path}.dmg",
|
||||||
"-mountpoint", Path(self.temp_dir.name / Path("payloads")),
|
"-mountpoint", Path(self.temp_dir.name / Path("payloads")),
|
||||||
"-nobrowse", "-shadow", Path(self.temp_dir.name / Path("payloads_overlay")),
|
"-nobrowse",
|
||||||
|
"-shadow", Path(self.temp_dir.name / Path("payloads_overlay")),
|
||||||
"-passphrase", "password"
|
"-passphrase", "password"
|
||||||
],
|
],
|
||||||
stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
stdout=subprocess.PIPE, stderr=subprocess.STDOUT
|
||||||
|
|||||||
Reference in New Issue
Block a user