Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Ruby/CLI: minify javascript + stylesheets, lossless image optimization

tag: v0.2.0

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 bin
Octocat-spinner-32 lib
Octocat-spinner-32 spec
Octocat-spinner-32 vendor
Octocat-spinner-32 .gitignore
Octocat-spinner-32 README.markdown
Octocat-spinner-32 Rakefile
Octocat-spinner-32 VERSION
Octocat-spinner-32 reduce.gemspec
README.markdown

Lossless reduction for js, css, jpg, png, gif

Install

install ruby + rubygems
sudo gem install reduce

Usage

reduce -o public/image.gif
reduce public/javascripts/application.js > public/javascripts/application.min.js

Options

-o, --overwrite                  overwrite file
-v, --version                    Show Version
-h, --help                       Show this.

Ruby

reduced_data = Reduce.reduce('files/bla.js')

How does it work?

  • uses web-based lossless image reduction service Smush.it / PunyPng through smusher
  • uses YUI compressor to minify css/js

Author

Michael Grosser
grosser.michael@gmail.com
Hereby placed under public domain, do what you want, just do not hold me accountable...

Something went wrong with that request. Please try again.