I have a Mac OS X application in the standard .app format and was wondering what is the easiest way to have a small script execute before the main program does. Is that possible?
Edit:
I only want to run the script once, so if I can set a flag or something after it runs that would be great!
Second Edit:
I do not have the XCode project so I cannot recompile anything, which is why I’m looking for another method.
If the app is relatively simple, you could just repackage it in another bundle. You could write a short program to run the script and then launch their executable, which you’d want to include in your bundle as a resource.
Of course, you’d also need to copy over all the original resources from the application.
Might I ask which program you are trying to run in this way?