使用Xcode命令行从iPhone下载应用程序的容器 [英] Download container for an app from iPhone using Xcode command line
问题描述
我已经开发了一个iOS应用,该应用保存了一些日志,这些日志显示在应用容器中.我可以使用Xcode>设备>选择应用>下载容器菜单选项来下载此容器.
I have developed an iOS app, this app saves some of the log, that appears in the applications container. I can download this container using Xcode > Device > Select App > Download Container menu option.
然后我可以在目录..../AppData/Documents/mylog.log
但是我想使它自动化,有没有办法通过命令行使用Xcode下载应用程序容器?
However I want to automate this, is there way to download an applications container using Xcode via command line?
推荐答案
有一个名为 ios-deploy的项目在github上. https://github.com/phonegap/ios-deploy
There is a project called ios-deploy on github. https://github.com/phonegap/ios-deploy
///下载应用程序的文档,库和tmp文件夹
ios-deploy --bundle_id'bundle.id'-下载-到MyDestinationFolder
// Download your app's Documents, Library and tmp folders
ios-deploy --bundle_id 'bundle.id' --download --to MyDestinationFolder
//列出应用程序的文档,库和tmp文件夹的内容
ios-deploy --bundle_id'bundle.id'--list
// List the contents of your app's Documents, Library and tmp folders
ios-deploy --bundle_id 'bundle.id' --list
//下载该应用程序的文档目录,仅
ios-deploy --download =/Documents --bundle_id my.app.id-至./my_download_location
// Download the Documents directory of the app only
ios-deploy --download=/Documents --bundle_id my.app.id --to ./my_download_location
此外,如果您的手机已经越狱,则在执行与文件操作有关的任何事情时,您将具有最大的灵活性. 例如,您可以使用'scp','rsyn';
Also, if you have a jailbreaked phone, you would have the most flexibility of do anything relative to file operations. For example you could copy files using tools like 'scp', 'rsyn';
这篇关于使用Xcode命令行从iPhone下载应用程序的容器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!