![](/img/trans.png)
[英]How to copy items from Documents directory to .app directory in iPhone App?
[英]How to view the app directory from iphone app
我尝试找出如何从iPhone应用程序查看应用程序目录。 有没有办法在xcode中查看我的应用程序的文件夹结构?
感谢您的任何提示。
您可以看到一个捆绑包(.app):
您必须在模拟器中运行它,然后检查文件夹:
~/Library/Application Support/iPhone Simulator/
您使用过的每个iOS版本都有一个子文件夹。 进入您正在使用的当前版本的iOS文件夹,其中将有一个名为Applications的子文件夹,并且其中有许多带有奇怪名称的子文件夹。 逐一检查它们,直到找到包含您的应用程序的一个:)
只是要尝试回答。 如何记录它,像这样:
//App Directory & Directory Contents
NSString *appFolderPath = [[NSBundle mainBundle] resourcePath];
NSFileManager *fileManager = [NSFileManager defaultManager];
NSLog(@"App Directory is: %@", appFolderPath);
NSLog(@"Directory Contents:\n%@", [fileManager directoryContentsAtPath: appFolderPath]);
要么
Xcode内部:
您必须先存档您的项目:
Select the device instead of the simulator (you don't have to plug a device in first).
Go to: Product -> Archive.
Open your Organizer (right upper corner).
Go to the Archive and right-click on your archived project, click on "Show in Finder".
在组织者中,选择项目后,xcode会告诉您该应用在应用商店中的大小。 实际大小是显示大小的一半。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.