AppleScript integration
planned
Vimcaw
According to the AppleScript documentation (https://developer.apple.com/library/archive/documentation/AppleScript/Conceptual/AppleScriptLangGuide/conceptual/ ASLR_about_handlers.html#//apple_ref/doc/uid/TP40000983-CH206-SW17), we can invoke commands from an app via AppleScript, which is very useful, as it allows us to implement some extensions to other software (such as PopClip and Raycast, etc.) and also allows us to automate some things.
For example, Spotify supports the playpuase command, so we can control the play/pause of Spotify by simply running "tell application "Spotify" to playpause".
So I hope this will be supported!
I'm not familiar with the syntax of AppleScript, but I've looked at it briefly to see that it is possible to call certain commands that the app listens to, and pass some arguments, and it seems to be possible to modify some app state, so I'll look into it when I have time to look at what APIs are needed.
Daniel Nguyen
planned
Daniel Nguyen
Updated: this is partially supported in v1.16.0 with the new AppleScript plugin.
Release note: https://boltai.canny.io/changelog/v1160-20-new-features
J
Jose
Daniel Nguyen What an update! Tons of features! I'm testing the applescript plugin and I'm impressed. This is like a preview of Apple Intelligence but maybe better. ChatGPT capable to execute almost anything in our macs (hopefully always under our control). Congrats!!
J
Jose
Daniel Nguyen I've got an issue trying to create an event in Apple Calendar through the Applescript plugin. I'm not able to give Bolt permissions to do it, even after granting them. I double checked the permission is granted in "System Preferences > Security & Privacy > Automation" and restarted the mac, but still getting "NSAppleScriptErrorBriefMessage = "Not authorized to send Apple events to Calendar."
An idea: do you think it's possible to view/copy the Applescript code used by the plugin? This way we can also learn from it.
Daniel Nguyen
in progress
Daniel Nguyen
planned
Yes. So my bigger vision is to build a plugin store/directory where users can build their own plugin & share with other.
I still need to work on the security and privacy aspect of it.
But my idea is to support bash (command line) and AppleScript. Will share more soon!