From 05a51bf32eeb9cfaa2be8624bca9739cfb594f2b Mon Sep 17 00:00:00 2001 From: Mykola Grymalyuk <48863253+khronokernel@users.noreply.github.com> Date: Wed, 19 May 2021 11:27:20 -0600 Subject: [PATCH] Update SysPatch.py --- Resources/SysPatch.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Resources/SysPatch.py b/Resources/SysPatch.py index 6952a1111..e58d57fa2 100644 --- a/Resources/SysPatch.py +++ b/Resources/SysPatch.py @@ -172,8 +172,12 @@ class PatchSysVolume: self.unpatch_root_vol() return True else: - print("- Mounting drive as writable") - self.elevated(["mount", "-o", "nobrowse", "-t", "apfs", f"/dev/{self.root_mount_path}", self.mount_location], stdout=subprocess.PIPE).stdout.decode().strip().encode() + if self.constants.recovery_status is True: + print("- Mounting drive as writable in Recovery") + self.elevated(["mount", "-t", "apfs", "-rw", f"/dev/{self.root_mount_path}", self.mount_location], stdout=subprocess.PIPE).stdout.decode().strip().encode() + else: + print("- Mounting drive as writable in OS") + self.elevated(["mount", "-o", "nobrowse", "-t", "apfs", f"/dev/{self.root_mount_path}", self.mount_location], stdout=subprocess.PIPE).stdout.decode().strip().encode() if Path(self.mount_extensions).exists(): print("- Successfully mounted the Root Volume") if patch is True: