jmcollin / optimizeImage

Shell - Allow you to optimize and compress your images

Repository from Github https://github.comjmcollin/optimizeImageRepository from Github https://github.comjmcollin/optimizeImage

Optimize Images

Allow you to optimize and compress your images in batches

Dependencies

Getting Started

To use this script, choose one of the following options to get started:

  • Download the latest release of Optimize Images
  • Fork this repository on GitHub

Installation

Locally

Installing Optimize Images locally is a matter of just running the script in your project directory:

Natsuflame@debian:home # git clone https://github.com/jmcollin/optimizeImage.git

Globally

Natsuflame@debian:home # cd optimizeImage/
Natsuflame@debian:optimizeImage # cp optimizeImage.sh /usr/bin/optimizeImage

Instruction for mozjpeg

Natsuflame@debian:home # cd mozjpeg/build/
Natsuflame@debian:build # cp cjpeg /usr/bin/mozcjpeg
Natsuflame@debian:build # cp djpeg /usr/bin/mozdjpeg
Natsuflame@debian:build # cp jpegtran /usr/bin/mozjpegtran

Usage

Usage: optimizeImage [OPTION]... SRC... DEST
  or   optimizeImage [OPTION]... SRC... [DEST]

Options
 -q 90, --quality 90         set quality (default ~ 90)
 -t jpg, png, gif            set image type (default ~ jpg)

 -d                          print dependencies
 --version                   print version number
(-h|-?) --help               show this help (-h is --help only if used alone)

Example Usage

Natsuflame@debian:optimizeImage # optimizeImage -t png src/ /home/optimizeImage/test/
Clean directory
Optipmize image(s)
[βœ”] ./PrestaShopAddons.png

[✘] Original Size: 72.78 KB
[βœ”] Savings Size: 58.99 KB
[βœ”] % Savings: 19.44%

Original image (72.8 KB):

alt text

Optimize image (59 KB):

alt text

Version

1.0.0

Copyright and License

Copyright 2014 Jean-Marie Collin. Code released under the MIT License license.

Theme used Copyright 2014 Iron Summit Media Strategies, LLC. Code released under the Apache 2.0 license.

About

Shell - Allow you to optimize and compress your images


Languages

Language:Shell 100.0%