Search code examples
xcode4

XCode resources on network drive. Safe to use?


I was wondering, if it is a recommended way to have graphic resources on a network drive. Here is my thoughts.

I use my windows machine to generate graphics for IOS apps. These graphics are stored on a shared drive I then copy those graphics into my xcode project and make a COPY into the project.

All is well, but i would like to reduce the number of steps involved.

Whenever i have to change a graphic, i have to use the windows machine, modify it, save it to the network drive, delete the images in the xcode project and copy the new files again.

I have noticed xcode works perfectly if the graphic resource is in a network drive (using reference to graphics rather than copying them).

But i was wondering, if this will effect the way the project is packaged when released? Will it make a difference if the images are stored on a network drive when i archive the project for release or i should have the graphics as a copy in the project?

Kindly advice


Solution

  • When Xcode builds an app bundle, it copies resource files into the bundle. It doesn't matter where the files are, as long as they're available and don't disappear while Xcode has the project open. The result is still the same: a local .app bundle somewhere with copies of the referenced resources in place.

    There are other concerns, though, that have to do with file systems. For example: Some are case sensitive; others are not. This can cause strange issues where the file is there - its there, dammit! - but Xcode insists it's not. Make sure you use a modern network file system and are aware of these possible file name issues.

    In short: No, this won't affect the built product; it'll only prevent you from building if the files are not available during the build process.