JamieMason / ImageOptim-CLI

Make optimisation of images part of your automated build process
https://foldleft.io/image-tools
MIT License
3.45k stars 125 forks source link

JPEGmini is not installed #187

Closed IsmailM closed 2 years ago

IsmailM commented 3 years ago

Steps To Reproduce The Error

Run imageoptim with the --jpegmini option.

Expected Behaviour

JPEG mini should run...

Actual Behaviour

I see the following error message:

⮀ imageoptim --jpegmini  figures/live_used/**/*jpg
! JPEGmini is not installed (https://itunes.apple.com/us/app/jpegmini/id498944723)
⮀ which jpegmini
jpegmini not found
⮀ ls /Applications/JPEGmini\ Pro.app
Contents

Version Numbers or N/A

ImageOptim CLI Version: 3.0.2 ImageOptim.app: 1.8.8 JPEGmini Pro.app: 3.1.0

Help Needed

I brought JPEGmini from https://www.jpegmini.com/ - since the app store link in the help text does not open in the UK...

Looking inside /Applications/JPEGmini\ Pro.app/Contents/Info.plist, I see that the bundle ID is:

    <key>CFBundleIdentifier</key>
    <string>com.beamr.jpegminipro.app</string>

From the code base, I see that it expects one of the following (which does not include the above):

https://github.com/JamieMason/ImageOptim-CLI/blob/e65bb4a24c23975297aac716cf77fc4b87827ef9/src/constants.ts#L68-L103

JamieMason commented 2 years ago

This should hopefully be fixed in 3.0.7