Minify images with Imagemin.
3 file formats supported. PNG
, JPEG
, GIF
Requires the Alfred 3 or 4 Powerpack, Node.js 8+.
Install with npm.
$ npm install --global alfred-imagemin
2020/12/07
Installation on npm will fail because of this issue.
Please install manually from here
download the workflow directly.
- Select images on finder.
- Open alfred and type
imagemin
and press the Enter key. - Output minify images in
optimized_images
folder.
You can set the compression rate and output dir with an environment variable.
name | default | value |
---|---|---|
JPEG_QUALITY | 70 | Option to imagemin-mozjpeg. Compression quality, in range 0 (worst) to 100 (perfect) |
PNG_MAX_QUALITY | 0.6 | Option to imagemin-pngquant. Compression max quality, in range 0 to 1 |
PNG_MIN_QUALITY | 0.5 | Option to imagemin-pngquant. Compression min quality, in range 0 to 1 |
GIF_OPTIMIZATION_LEVEL | 3 | Option to imagemin-gifsicle. Select an optimization level between 1 and 3. |
OUTPUT_DIR | optimized_images | Optimized image output directory name |
- alfy - Create Alfred workflows with ease
- imagemin - Minify images seamlessly
- imagemin-pngquant - Imagemin plugin for
pngquant
- imagemin-mozjpeg - Imagemin plugin for
mozjpeg
- imagemin-gifsicle - - Imagemin plugin for
gifsicle
MIT ©