How do you run package files with your application?
I have been building a Cocoa application and I've gotten most of the code worked out. At this point I have the application itself, a .command files to run some things from terminal, and a folder used to store files needed to run the .command开发者_如何学运维 properly. Is there a way to put the .command file and the folder inside the application and still run them? By inside I mean inside the package contents of the .app.
You can use NSBundle to find the path to a file (or folder) inside your application bundle, or in any other bundle.
精彩评论