babashka / obb

Ad-hoc ClojureScript scripting of Mac applications via Apple's Open Scripting Architecture.
Eclipse Public License 1.0
241 stars 5 forks source link

Usefulness of an .app #5

Closed willcohen closed 2 years ago

willcohen commented 2 years ago

I was thinking this morning that an eventual option alongside the cli might be an .app as well -- it seems, at first glance, like the biggest outstanding difference between something like Hammerspoon and this is that obb still has no clear capability for running outside of an ad-hoc manner. If there were a canonical obb.app that could startup and listen for events, it could collect various ad-hoc additional scripts and respond to those events accordingly.

What I still haven't thought through in any detail is how that would work. Could it be as simple as, ultimately, a "fancy" .cljs script that itself uses obb to create a process that can load and unload scripts and perhaps even spit out a really simple GUI? If so, then I suppose the hardest part would be thinking through the eventual API for what can be listened to, and how scripts can be loaded and unloaded.