Skip to content

Commit

Permalink
fix something
Browse files Browse the repository at this point in the history
  • Loading branch information
DargonLee committed Sep 27, 2024
1 parent 007e11f commit 3092a06
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
12 changes: 10 additions & 2 deletions esign/app_info_manager.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import asyncio
import json
import os
import plistlib
Expand Down Expand Up @@ -63,6 +62,15 @@ def modify_bundle_name(self, new_bundle_name: str):

def delete_support_devices(self):
self._delete_item_value(self.info_plist_file_path, "UISupportedDevices")
self.logger.default(f"Deleting: UISupportedDevices")

def read_info_content(self):
try:
with open(self.info_plist_file_path, 'rb') as f:
plist_content = plistlib.load(f)
self.logger.info(f"Info.plist content: {plist_content}")
except Exception as e:
self.logger.error(f"Failed to read Info.plist content: {str(e)}")

def get_executable_name(self) -> str:
executable_name = self._get_plist_value(self.info_plist_file_path, "CFBundleExecutable")
Expand Down Expand Up @@ -124,4 +132,4 @@ def _get_plist_value(self, plist_path: str, key: str) -> str:

def _delete_item_value(self, plist_path: str, key: str):
cmd = f'/usr/libexec/PlistBuddy -c "Delete :{key}" {plist_path}'
subprocess.getoutput(cmd).strip()
return subprocess.getoutput(cmd).strip()
1 change: 0 additions & 1 deletion esign/app_preparation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import asyncio
import os
import shutil
import zipfile
Expand Down
2 changes: 0 additions & 2 deletions esign/app_signer.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,13 @@
import os
from typing import Dict

from regex import F
from esign.app_preparation import AppPreparation
from esign.code_signing import CodeSigning
from esign.econfig import ConfigHandler
from esign.dylib_injector import DylibInjector
from esign.entitlements_manager import EntitlementsManager
from esign.ipa_packager import IPAPackager
from esign.elogger import Logger
from esign.exceptions import ESignError
from esign.app_info_manager import AppInfoManager
from esign.app_installer import AppInstaller
from esign.symbol_restorer import SymbolRestorer
Expand Down
1 change: 0 additions & 1 deletion esign/encryption_checker.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import os
import shutil
import subprocess
from turtle import st

from esign.elogger import Logger
from esign.econfig import ConfigHandler
Expand Down

0 comments on commit 3092a06

Please sign in to comment.