When comparing ImageOptim vs Hammerspoon, the Slant community recommends ImageOptim for most people. In the question“What are the best power user tools for macOS?” ImageOptim is ranked 8th while Hammerspoon is ranked 38th. The most important reason people chose ImageOptim is:
Great for compressing images for web usage or saving harddrive space.
Specs
Ranked in these QuestionsQuestion Ranking
Pros
Pro Losslessly compresses PNG, GIF, and JPEG images
Great for compressing images for web usage or saving harddrive space.
Pro Fast & Simple
Pro Simple drag'n' drop interface
Simply drag images (or folders) into the window.
Pro Tries several different image optimizers before picking the best one
Pro Edits files in place
It does edit files in place, overwriting the original. This is exactly what I want, so I love it, but it's good to know beforehand.
Pro Can handle PNG, GIF, and JPEG images
Great for compressing images for web usage or saving harddrive space.
Pro 1512 issues are closed in the download page in GitHub
https://github.com/Hammerspoon/hammerspoon/issues
They do fix issues that come from the community.
Pro Deeply customizable
Hammerspoon's Lua scripting and broad API allows you to perform any action you can imagine on your mac. It hooks into many OS APIs directly and has some high-level APIs to manipulate things like Spotify or iTunes. See the full list here.
Pro Automate actions based on the operating system
Hammerspoon lets you hook into OS level events and trigger any action you can imagine. From setting up a simple keyboard shortcut to launching a complex workflow using multiple apps and scripts.
Cons
Con Compression algorithm not as good as counterparts
Con Cannot abort an optimization
Optimization can run for a long time. Sometimes it reaches 20% quickly and then spend a long time to attain 21.2%. But you cannot interrupt the process.
Con Does not work on SVG yet
Con Has 324 issues on their download page in GitHub
https://github.com/Hammerspoon/hammerspoon/issues
I can not list all the issues.
Con Some knowledge of programming required
Hammerspoon is scripted in the Lua programming language, and some familiarity with programming in general will be needed to use it. Some plugins exist that can be used by adding some files to a specific folder, but this will not give the flexibility that is so key to Hammerspoon