This is a scripting addition which adds a new Apple Script command to inject F-Script to any application.
git clone git://github.com/binaryage/fscript-osax.git cd fscript-osax xcodebuild
If you see
** BUILD SUCCEEDED ** that means that you have FScript.osax installed in
How to inject F-Script into an app?
- Install F-Script.
- Let's say you want to inject F-Script into Safari...
tell application "Safari" to «event BAFSinjc»
osascript -e "tell application \"Safari\" to «event BAFSinjc»"
You have to relaunch Safari after first installation of FScript.osax. In other case the AppleScript will fail.
Applications without main menu
You may use apple events to control F-Script menu item:
osascript -e "tell application \"Safari\" to «event BAFSscon» -- show console" osascript -e "tell application \"Safari\" to «event BAFSoobr» -- open object browser" osascript -e "tell application \"Safari\" to «event BAFSsppa» -- show preference panel"
By installing F-Script you should place framework in
/Library/Frameworks/FScript.framework. This is default location.
If you need to inject different version or a framework from different location, please create
~/.fscript-framework-location text file with a new path to your FScript.framework.