separate directory for iphone resources

2019-02-25 12:32发布

iPhone resources by default show up in a "Resources" group that's visible in the main xcode project view. I want to be able to put them into an actual, physically separate directory at some arbitrary location on my machine decided by me. Interestingly enuf, the default "Classes" group is an actual, physical directory but the "Resources" group isn't.

How can someone tell me how to do that? TIA, Howard

3条回答
爱情/是我丢掉的垃圾
2楼-- · 2019-02-25 13:15

Right click on Resources, add existing files, choose your directory
and select "Create Folder References for any added folders".

Voilà.

查看更多
别忘想泡老子
3楼-- · 2019-02-25 13:28

Both the abovementioned approaches are just how-tos. These operation will transform into build setting. Here is how you can change (or at least just view) the setting on XCode.

If you are using XCode 4+, check the project icon, then select your Target. In Build Phases tab, looking for "Copy Bundle Resources (x items)" category. In it, you should have your folder there. If no, click "+" button.

查看更多
forever°为你锁心
4楼-- · 2019-02-25 13:29

An alternate approach is to start with a directory in your project with some files, drag it into Xcode and have it create the folder references for you. Anything you add within that folder reference is automatically put in that subdirectory.

查看更多
登录 后发表回答