@@ -48,7 +48,7 @@ class color:
4848print ("\n \n " + color .BOLD + color .RED + "↺ RESET ALL COMPONENTS LOCALLY" + color .END ,"" )
4949print (" Please wait\n " )
5050print (color .END + "\n \n \n Checking integrity...\n \n \n \n \n " )
51- if os .path .exists ("./resources/oc_store/compat_new/OpenCore.qcow2" ) and os .path .exists ("./resources/oc_store/compat_old/OpenCore.qcow2" ) and os .path .exists ("./resources/ovmf/OVMF_CODE.fd" ) and os .path .exists ("./resources/ovmf/OVMF_VARS.fd" ) and os .path .exists ("./resources/ovmf/OVMF_VARS-1280x720.fd" ) and os .path .exists ("./resources/oc_store/compat_new/config.plist" ):
51+ if os .path .exists ("./resources/oc_store/compat_new/OpenCore.qcow2" ) and os .path .exists ("./resources/oc_store/compat_old/OpenCore.qcow2" ) and os .path .exists ("./resources/ovmf/OVMF_CODE.fd" ) and os .path .exists ("./resources/ovmf/OVMF_VARS.fd" ) and os .path .exists ("./resources/ovmf/OVMF_VARS-1280x720.fd" ) and os .path .exists ("./resources/oc_store/compat_new/config.plist" ) and os . path . exists ( "./resources/script_store/extras.py" ) and os . path . exists ( "./resources/script_store/setup.py" ) :
5252 integrity = 1
5353else :
5454 integrity = 0
@@ -63,7 +63,7 @@ class color:
6363print ("\n \n " + color .BOLD + color .RED + "↺ RESET ALL COMPONENTS LOCALLY" + color .END ,"" )
6464print (" Restore to default state\n " )
6565
66- print (color .BOLD + " Integrity Check " )
66+ print (color .BOLD + " Integrity" )
6767if integrity == 1 :
6868 print (color .GREEN + color .BOLD + " ●" + color .END + " PASSED" )
6969else :
@@ -77,6 +77,7 @@ class color:
7777 print (color .BOLD + color .GREEN + " WILL " + color .END + "replace the OVMF code with a new copy" )
7878 print (color .BOLD + color .GREEN + " WILL " + color .END + "fix permissions on resources" )
7979 print (color .BOLD + color .YELLOW + " MIGHT " + color .END + "fix some quirky issues" )
80+ print (color .BOLD + color .YELLOW + " MIGHT " + color .END + "restore older versions of repository files" )
8081 print (color .BOLD + color .RED + " WILL NOT " + color .END + "delete your configs or vHDD files" )
8182 print (color .BOLD + color .RED + " WILL NOT " + color .END + "create a backup of reset files" )
8283
@@ -122,9 +123,10 @@ def throwError():
122123 #os.system("rm ./blobs/*.apb > /dev/null 2>&1")
123124 #os.system("rm ./blobs/stale/*.apb > /dev/null 2>&1")
124125 os .system ("rm ./resources/config.sh > /dev/null 2>&1" )
125- os .system ("chmod +x -R scripts/*.py" )
126- os .system ("chmod +x -R scripts/*.sh" )
127- os .system ("chmod +x resources/dmg2img" )
126+ os .system ("rm ./setup.py > /dev/null 2>&1" )
127+ os .system ("rm ./scripts/* > /dev/null 2>&1" )
128+ os .system ("rm ./scripts/restore/* > /dev/null 2>&1" )
129+ os .system ("rm ./scripts/extras/* > /dev/null 2>&1" )
128130 time .sleep (4 )
129131
130132 global USR_TARGET_OS
@@ -150,7 +152,8 @@ def throwError():
150152 os .system ("cp -R resources/oc_store/compat_new/EFI boot/EFI" )
151153
152154
153-
155+ os .system ("cp -R ./resources/script_store/* ./scripts/" )
156+ os .system ("mv ./scripts/setup.py ./setup.py" )
154157 os .system ("cp ./resources/ovmf/OVMF_CODE.fd ./ovmf/OVMF_CODE.fd" )
155158 os .system ("cp ./ovmf/var/OVMF_VARS.fd ./ovmf/OVMF_VARS.fd" )
156159
@@ -160,7 +163,10 @@ def throwError():
160163 if os .path .exists ("boot/OpenCore.qcow2" ):
161164 if os .path .exists ("ovmf/OVMF_CODE.fd" ):
162165 if os .path .exists ("boot/EFI/" ):
163- success ()
166+ if os .path .exists ("scripts/extras.py" ):
167+ success ()
168+ else :
169+ throwError ()
164170 else :
165171 throwError ()
166172 else :
0 commit comments