mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-06-20 14:10:51 +10:00
Add basic app building
Currently non-functional
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
.DS_Store
|
.DS_Store
|
||||||
|
/App
|
||||||
/Build-Folder
|
/Build-Folder
|
||||||
/.vscode
|
/.vscode
|
||||||
__pycache__/
|
__pycache__/
|
||||||
|
|||||||
Executable
+51
@@ -0,0 +1,51 @@
|
|||||||
|
#!/usr/bin/env python
|
||||||
|
from __future__ import print_function
|
||||||
|
|
||||||
|
from shutil import copy
|
||||||
|
from shutil import rmtree
|
||||||
|
from distutils.dir_util import copy_tree
|
||||||
|
|
||||||
|
import os
|
||||||
|
import json
|
||||||
|
import subprocess
|
||||||
|
import sys
|
||||||
|
import zipfile
|
||||||
|
|
||||||
|
os.chdir(os.path.dirname(os.path.realpath(__file__)))
|
||||||
|
current_path = os.getcwd()
|
||||||
|
|
||||||
|
print(current_path)
|
||||||
|
|
||||||
|
# File location
|
||||||
|
command_path = os.path.join(current_path, "OpenCore-Patcher.command")
|
||||||
|
resources_path = os.path.join(current_path, "Resources/")
|
||||||
|
payloads_path = os.path.join(current_path, "payloads/")
|
||||||
|
icns_path = os.path.join(current_path, "OC-Patcher.icns")
|
||||||
|
plist_path = os.path.join(current_path, "Info.plist")
|
||||||
|
|
||||||
|
app_path = os.path.join(current_path, "App/")
|
||||||
|
app_app_path = os.path.join(current_path, "App/OpenCore-Patcher.app/")
|
||||||
|
contents_path = os.path.join(current_path, "App/OpenCore-Patcher.app/Contents/")
|
||||||
|
app_macos_path = os.path.join(current_path, "App/OpenCore-Patcher.app/Contents/MacOS/")
|
||||||
|
app_macos_payload_path = os.path.join(current_path, "App/OpenCore-Patcher.app/Contents/MacOS/payloads")
|
||||||
|
app_macos_resources_path = os.path.join(current_path, "App/OpenCore-Patcher.app/Contents/MacOS/Resources")
|
||||||
|
app_resources_path = os.path.join(current_path, "App/OpenCore-Patcher.app/Contents/Resources/")
|
||||||
|
|
||||||
|
if os.path.exists(app_path):
|
||||||
|
print("Cleaning App folder")
|
||||||
|
rmtree(app_path)
|
||||||
|
|
||||||
|
print("Creating new App folder")
|
||||||
|
os.mkdir(app_path)
|
||||||
|
os.mkdir(app_app_path)
|
||||||
|
os.mkdir(contents_path)
|
||||||
|
os.mkdir(app_macos_path)
|
||||||
|
os.mkdir(app_resources_path)
|
||||||
|
|
||||||
|
copy(command_path, app_macos_path)
|
||||||
|
copy_tree(resources_path, app_macos_resources_path)
|
||||||
|
copy_tree(payloads_path, app_macos_payload_path)
|
||||||
|
copy(icns_path, app_resources_path)
|
||||||
|
copy(plist_path, contents_path)
|
||||||
|
|
||||||
|
|
||||||
+32
@@ -0,0 +1,32 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||||
|
<plist version="1.0">
|
||||||
|
<dict>
|
||||||
|
<key>CFBundleDevelopmentRegion</key>
|
||||||
|
<string>English</string>
|
||||||
|
<key>CFBundleExecutable</key>
|
||||||
|
<string>OpenCore-Patcher.command</string>
|
||||||
|
<key>CFBundleIconFile</key>
|
||||||
|
<string>OC-Patcher.icns</string>
|
||||||
|
<key>CFBundleIdentifier</key>
|
||||||
|
<string>com.dortania.OpenCore-Patcher</string>
|
||||||
|
<key>CFBundleInfoDictionaryVersion</key>
|
||||||
|
<string>0.0</string>
|
||||||
|
<key>CFBundleName</key>
|
||||||
|
<string>OpenCore-Patcher</string>
|
||||||
|
<key>CFBundlePackageType</key>
|
||||||
|
<string>APPL</string>
|
||||||
|
<key>CFBundleShortVersionString</key>
|
||||||
|
<string>0.0</string>
|
||||||
|
<key>CFBundleSignature</key>
|
||||||
|
<string>????</string>
|
||||||
|
<key>CFBundleVersion</key>
|
||||||
|
<string>0.0</string>
|
||||||
|
<key>LSMinimumSystemVersion</key>
|
||||||
|
<string>10.4</string>
|
||||||
|
<key>LSMultipleInstancesProhibited</key>
|
||||||
|
<true/>
|
||||||
|
<key>NSHumanReadableCopyright</key>
|
||||||
|
<string>Copyright 2020 Dortania</string>
|
||||||
|
</dict>
|
||||||
|
</plist>
|
||||||
Binary file not shown.
Reference in New Issue
Block a user