BridgePlus in ASOC

Hey there,

i discovered Shane’s BridgePlus and i love it. It works great from within pure Applescripts.
Now i try to get it to work within an ASOC XCode project, but i cant seem to get it to work.

How do i have to implement it?
Any help appreciated.

One way is to add just the framework to your project. Open the library bundle, and it’s in /Contents/Frameworks. As well as linking to it, you’ll probably need to add a Build Phase to copy it into your target.

That said, you can also add the full library. Add a Build Phase to copy it to Resources with a Subpath of Script Libraries, and add these two lines to the start of any script files that want to use it:

use script "BridgePlus"
use scripting additions

I’m trying to add BridgePlus framework to Xcode 7.3.1. I’m dragging BridgePlus.framework from within the Package Contents of the BridgePlus bundle to my Xcode project and choose to “copy items if needed” and “add to targets” checked. Link Binary with Libraries shows the BridgePlus.framework is linked and required.

What do I need to do specifically to add a build phase?

Running it now gives me an error…
dyld: Library not loaded: @rpath/BridgePlus.framework/Versions/A/BridgePlus
Referenced from: /Users/flameCoder/Library/Developer/Xcode/DerivedData/Test-cdnoyokimsxzrmdysyhwydxkylfz/Build/Products/Debug/Test.app/Contents/MacOS/Test
Reason: image not found

With the Target selected, click on the Build Phases tab. Click on the + at the top-left and choose New Copy Files Phase. Expand the new Copy Files entry, change the Destination to Frameworks, and click the + button at the bottom to choose the framework.

That did it!
Great as always. Thank you.

Edit: is there a method to easily “Cocoaify” a text to NSString?

You can use the class method CocoaifyFrom:, but don’t see any advantage.