I\'m trying to load some .applescript files in my project.
Copied them into the \"Supporting Files\" directory like this:
Great response from Zaph above, but I noticed when I was doing it there's quicker way, at least in Xcode 6.1.
if you single click the file (eg. test.applescript) and have the right menu of Xcode open, you'll see a section called "Target Membership". Make sure that the right target (as in the one you're using the script with) is selected and it'll do the same job as adding the file under "Copy Bundle Resources"
Also, not entirely relevant but in case you're loading from several different places, or you are inheriting this class. You shouldn't really use
[NSBundle mainBundle];
instead use
[NSBundle bundleForClass:[self class]];
That means you don't have to worry about where you are on the method call it'll take the resource from the appropriate items associated with the target you're running. Great for making libraries and reusable calls ;)