macOS Automation with Lua scripts via Hammerspoon
A fellow Mac developer shared one of his open source projects: Hammerspoon.
It is two things, really:
- It's a bridge of many (all?) macOS API that people would use from Swift or Objective-C to Lua.
- It's an app that runs in the background to execute your scripts.
The "API bridge" may not make sense to those of you who are less technical inclined. It basically means you can write macOS tools in a scripting language, Lua. You can create custom windows and draw stuff. It can do a lot of stuff: Window management, system-wide hot keys, app switching, working with AirPods, switching display resolutions, react to USB devices being plugged in, ...
- Website: http://www.hammerspoon.org/
- Directory of demo scripts, called "Spoons": https://www.hammerspoon.org/Spoons/ (Source codes)
- Here's an example of a floating clock.
- And here's an example that displays a system notification when your Leanpub book is ready.
Author at Zettelkasten.de • https://christiantietze.de/
Howdy, Stranger!