Skip to content

SharpeRAD/Cake.ImageOptimizer

Repository files navigation

Cake.ImageOptimizer

Cake Build addin for optimizing images

Build status

cakebuild.net

Join the chat at https://gitter.im/cake-build/cake

Table of contents

  1. Implemented functionality
  2. Referencing
  3. Usage
  4. Example
  5. Plays well with
  6. License
  7. Share the love

Implemented functionality

  • Kraken.io

Referencing

NuGet Version NuGet Downloads

Cake.ImageOptimizer is available as a nuget package from the package manager console:

Install-Package Cake.ImageOptimizer

or directly in your build script via a cake addin directive:

#addin "Cake.ImageOptimizer"

Usage

#addin "Cake.ImageOptimizer"

Task("Optimize")
    .Description("Optimize images")
    .Does(() =>
{
    var settings = new ImageOptimizerSettings()
    {
        Services = "Kraken",
        SearchFilter = "*.png",
        ConfigFile = "./Files/config.xml"
    };

    OptimizeImages("./Files/Source", "./Files/Destination", settings);
});

RunTarget("Optimize");

Example

A complete Cake example can be found here.

TroubleShooting

  • Please be aware of the breaking changes that occurred with the release of Cake v0.22.0, you will need to upgrade Cake in order to use Cake.Services v0.1.0 or above.

Plays well with

If your looking to store images in S3 check out Cake.AWS.S3.

If your looking to distribute your images using CloudFront's CDN then check out Cake.AWS.CloudFront.

License

Copyright (c) 2015 - 2017 Phillip Sharpe

Cake.ImageOptimizer is provided as-is under the MIT license. For more information see LICENSE.

Share the love

If this project helps you in anyway then please ⭐ the repository.

About

Image optimization addin for Cake

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published