从本地的plist(空)安装iOS应用想安装(Installing iOS Apps from a

2019-06-25 20:52发布

我试图从设备的文件系统中的plist安装iOS应用程序。

NSString *launchNewPlistURL = [NSString stringWithFormat:@"itms-services://?action=download-manifest&url=file://%@",[self saveFilePath]];
[[UIApplication sharedApplication]openURL:[NSURL URLWithString:launchNewPlistURL]];

而我提示“(空)想安装{} myappname”。 通常(空)是的plist是来自域名,但在这种情况下,它是零,因为它是一个本地文件。

反正是有指定标题中的plist或URL传递一个假域名?

谢谢,丹

Answer 1:

您可以使用项目MongooseDaemon创建HTTP本地服务器。

随着类似于领域: http://192.168.xxx.xxx/yourplist.plist安装它。

总之,我认为你不能有大的IPA使用它。 我试图用我比15MB IPA更大,这是非常,非常缓慢的开始安装。



Answer 2:

我是在一个类似的情况,并通过使用猫鼬原来的路线去了,但就在今天偶然CocoaHttpServer 。

随着猫鼬,我只是得到关于充当了当地的plist / IPA文件有20%的成功率。 有时候localhost would like to install对话框一直没上,有时安装开始,大约一半是失败的,有时它实际工作。 更糟的是,一旦一个应用程序失败,我必须完全卸载并重新安装,那么所有的数据丢失。 我从来没有能够成功地“解决”一个失败的安装。

到目前为止,只有约10-15分钟的测试中,CocoaHttpServer没有失败,但。 我知道这是一个非常小的样本量,但我的猫鼬的成功率为10%左右。

self.httpServer = [[HTTPServer alloc] init];
[self.httpServer setType:@"_http._tcp."];
[self.httpServer setPort:8080];
//This is just a path where I save my IPA and Plist file locally.  
//In my case it's /{NSDocumentDirectory}/install/
[self.httpServer setDocumentRoot:[self pathForLocalInstallFiles]];

然后URL到磁盘上的plist:

NSURL *plistUrl = [NSURL URLWithString:@"itms-services://?action=download-manifest&url=http://localhost:8080/appname.plist"];
[[UIApplication sharedApplication] openURL:plistUrl];

plist中,你有你的URL指向本地IPA文件里面,我使用了两种成功file://http://localhost/



文章来源: Installing iOS Apps from a local plist (null) would like to install
标签: ios null ipa adhoc