mirror of
https://github.com/SideStore/SideStore.git
synced 2026-03-27 21:05:39 +01:00
minimuxer: use newly exposed Swift wrappers in MinimuxerWrapper.swift
This commit is contained in:
@@ -12,6 +12,7 @@ import AltStoreCore
|
|||||||
import Roxas
|
import Roxas
|
||||||
|
|
||||||
import Nuke
|
import Nuke
|
||||||
|
import Minimuxer
|
||||||
|
|
||||||
class BrowseViewController: UICollectionViewController, PeekPopPreviewing
|
class BrowseViewController: UICollectionViewController, PeekPopPreviewing
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ final class LaunchViewController: UIViewController, UIDocumentPickerDelegate {
|
|||||||
try! FileManager.default.removeItem(at: FileManager.default.documentsDirectory.appendingPathComponent(pairingFileName))
|
try! FileManager.default.removeItem(at: FileManager.default.documentsDirectory.appendingPathComponent(pairingFileName))
|
||||||
displayError("minimuxer failed to start, please restart SideStore. \((error as? LocalizedError)?.failureReason ?? "UNKNOWN ERROR")")
|
displayError("minimuxer failed to start, please restart SideStore. \((error as? LocalizedError)?.failureReason ?? "UNKNOWN ERROR")")
|
||||||
}
|
}
|
||||||
start_auto_mounter(documentsDirectory)
|
startAutoMounter(documentsDirectory)
|
||||||
}
|
}
|
||||||
|
|
||||||
func fetchPairingFile() -> String? { PairingFileManager.shared.fetchPairingFile(presentingVC: self) }
|
func fetchPairingFile() -> String? { PairingFileManager.shared.fetchPairingFile(presentingVC: self) }
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ import WidgetKit
|
|||||||
import AltStoreCore
|
import AltStoreCore
|
||||||
import AltSign
|
import AltSign
|
||||||
import Roxas
|
import Roxas
|
||||||
|
import Minimuxer
|
||||||
|
|
||||||
extension AppManager
|
extension AppManager
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -701,7 +701,7 @@ private extension AuthenticationOperation
|
|||||||
|
|
||||||
func registerCurrentDevice(for team: ALTTeam, session: ALTAppleAPISession, completionHandler: @escaping (Result<ALTDevice, Error>) -> Void)
|
func registerCurrentDevice(for team: ALTTeam, session: ALTAppleAPISession, completionHandler: @escaping (Result<ALTDevice, Error>) -> Void)
|
||||||
{
|
{
|
||||||
guard let udid = fetch_udid()?.toString() else {
|
guard let udid = fetchUDID() else {
|
||||||
return completionHandler(.failure(OperationError.unknownUDID))
|
return completionHandler(.failure(OperationError.unknownUDID))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -118,7 +118,7 @@ final class BackgroundRefreshAppsOperation: ResultOperation<[String: Result<Inst
|
|||||||
if #available(iOS 17, *) {
|
if #available(iOS 17, *) {
|
||||||
// TODO: iOS 17 and above have a new JIT implementation that is completely broken in SideStore :(
|
// TODO: iOS 17 and above have a new JIT implementation that is completely broken in SideStore :(
|
||||||
} else {
|
} else {
|
||||||
start_auto_mounter(documentsDirectory)
|
startAutoMounter(documentsDirectory)
|
||||||
}
|
}
|
||||||
|
|
||||||
self.managedObjectContext.perform {
|
self.managedObjectContext.perform {
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ final class DeactivateAppOperation: ResultOperation<InstalledApp>
|
|||||||
|
|
||||||
for profile in allIdentifiers {
|
for profile in allIdentifiers {
|
||||||
do {
|
do {
|
||||||
try remove_provisioning_profile(profile)
|
try removeProvisioningProfile(profile)
|
||||||
self.progress.completedUnitCount += 1
|
self.progress.completedUnitCount += 1
|
||||||
installedApp.isActive = false
|
installedApp.isActive = false
|
||||||
self.finish(.success(installedApp))
|
self.finish(.success(installedApp))
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ final class EnableJITOperation<Context: EnableJITContext>: ResultOperation<Void>
|
|||||||
var retries = 3
|
var retries = 3
|
||||||
while (retries > 0){
|
while (retries > 0){
|
||||||
do {
|
do {
|
||||||
try debug_app(installedApp.resignedBundleIdentifier)
|
try debugApp(installedApp.resignedBundleIdentifier)
|
||||||
self.finish(.success(()))
|
self.finish(.success(()))
|
||||||
retries = 0
|
retries = 0
|
||||||
} catch {
|
} catch {
|
||||||
@@ -105,7 +105,7 @@ final class EnableJITOperation<Context: EnableJITContext>: ResultOperation<Void>
|
|||||||
|
|
||||||
@available(iOS 17, *)
|
@available(iOS 17, *)
|
||||||
func enableJITSideJITServer(serverURL: URL, installedApp: InstalledApp, completion: @escaping (Result<Void, SideJITServerErrorType>) -> Void) {
|
func enableJITSideJITServer(serverURL: URL, installedApp: InstalledApp, completion: @escaping (Result<Void, SideJITServerErrorType>) -> Void) {
|
||||||
guard let udid = fetch_udid()?.toString() else {
|
guard let udid = fetchUDID() else {
|
||||||
completion(.failure(.other("Unable to get UDID")))
|
completion(.failure(.other("Unable to get UDID")))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,6 +11,8 @@ import AltStoreCore
|
|||||||
import AltSign
|
import AltSign
|
||||||
import Roxas
|
import Roxas
|
||||||
|
|
||||||
|
import Minimuxer
|
||||||
|
|
||||||
@objc(RefreshAppOperation)
|
@objc(RefreshAppOperation)
|
||||||
final class RefreshAppOperation: ResultOperation<InstalledApp>
|
final class RefreshAppOperation: ResultOperation<InstalledApp>
|
||||||
{
|
{
|
||||||
@@ -46,7 +48,6 @@ final class RefreshAppOperation: ResultOperation<InstalledApp>
|
|||||||
|
|
||||||
for p in profiles {
|
for p in profiles {
|
||||||
do {
|
do {
|
||||||
let bytes =
|
|
||||||
try installProvisioningProfiles(p.value.data)
|
try installProvisioningProfiles(p.value.data)
|
||||||
} catch {
|
} catch {
|
||||||
self.finish(.failure(MinimuxerError.ProfileInstall))
|
self.finish(.failure(MinimuxerError.ProfileInstall))
|
||||||
|
|||||||
@@ -201,7 +201,7 @@ private extension ResignAppOperation
|
|||||||
|
|
||||||
if app.isAltStoreApp
|
if app.isAltStoreApp
|
||||||
{
|
{
|
||||||
guard let udid = fetch_udid()?.toString() as? String else { throw OperationError.unknownUDID }
|
guard let udid = fetchUDID() else { throw OperationError.unknownUDID }
|
||||||
guard Bundle.main.object(forInfoDictionaryKey: Bundle.Info.devicePairingString) is String else { throw OperationError.unknownUDID }
|
guard Bundle.main.object(forInfoDictionaryKey: Bundle.Info.devicePairingString) is String else { throw OperationError.unknownUDID }
|
||||||
additionalValues[Bundle.Info.devicePairingString] = "<insert pairing file here>"
|
additionalValues[Bundle.Info.devicePairingString] = "<insert pairing file here>"
|
||||||
additionalValues[Bundle.Info.deviceID] = udid
|
additionalValues[Bundle.Info.deviceID] = udid
|
||||||
|
|||||||
@@ -8,6 +8,8 @@
|
|||||||
import Foundation
|
import Foundation
|
||||||
import Network
|
import Network
|
||||||
import AltStoreCore
|
import AltStoreCore
|
||||||
|
import Minimuxer
|
||||||
|
|
||||||
|
|
||||||
@objc(SendAppOperation)
|
@objc(SendAppOperation)
|
||||||
final class SendAppOperation: ResultOperation<()>
|
final class SendAppOperation: ResultOperation<()>
|
||||||
|
|||||||
Reference in New Issue
Block a user