Skip to content

Instantly share code, notes, and snippets.

@gayanvirajith
Created December 18, 2014 08:37
Show Gist options
  • Save gayanvirajith/e452adab8e0e384b81d8 to your computer and use it in GitHub Desktop.
Save gayanvirajith/e452adab8e0e384b81d8 to your computer and use it in GitHub Desktop.
Gulp image minify
var gulp = require('gulp'),
imagemin = require('gulp-imagemin');
var pngcrush = require('imagemin-pngcrush');
// Gulp task - images
gulp.task('images', function() {
gulp.src('images/**')
.pipe(imagemin({ optimizationLevel: 3, progressive: true, interlaced: true, use: [] }))
.pipe(gulp.dest('min/'));
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment