{"_id":"grunt-image-resize","_rev":"35-830cb1353ca8466c1c9decf492e5de5b","name":"grunt-image-resize","dist-tags":{"latest":"1.0.0"},"versions":{"0.1.0":{"name":"grunt-image-resize","version":"0.1.0","keywords":["gruntplugin"],"author":{"url":"http://excellenteasy.com","name":"David Pfahler","email":"david@excellenteasy.com"},"_id":"grunt-image-resize@0.1.0","maintainers":[{"name":"excellenteasy","email":"info@excellenteasy.com"}],"homepage":"https://github.com/excellenteasy.com/grunt-image-resize","bugs":{"url":"https://github.com/excellenteasy.com/grunt-image-resize/issues"},"dist":{"shasum":"4bfa5bd5a3b7361fdc105f0b839200a61622b598","tarball":"https://registry.npmjs.org/grunt-image-resize/-/grunt-image-resize-0.1.0.tgz","integrity":"sha512-bcEJS/I/yKQunJisVGGUpgsxdziQ52zBcEnZwp+W2oE5XURKjzYfBj0ZACo16UiJzBYoQep1+HJGx5nEsZzJNQ==","signatures":[{"sig":"MEQCIC+phYB/Lq9b+7bbTcboUD03zqY1cTmTpmocExPS7eJPAiAD4uNqmsBPmgCo6/7IX+Hahf+Kigwar3EAzXR4r0FDiQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"Gruntfile.js","engines":{"node":">= 0.8.0"},"scripts":{"test":"grunt test"},"_npmUser":{"name":"excellenteasy","email":"info@excellenteasy.com"},"licenses":[{"url":"https://github.com/excellenteasy.com/grunt-image-resize/blob/master/LICENSE-MIT","type":"MIT"}],"repository":{"url":"git://github.com/excellenteasy.com/grunt-image-resize","type":"git"},"_npmVersion":"1.1.49","description":"Resizing images made easy.","dependencies":{"node-imagemagick":"~0.1.8"},"devDependencies":{"grunt-contrib-clean":"~0.4.0","grunt-contrib-jshint":"~0.1.1","grunt-contrib-nodeunit":"~0.1.2"},"peerDependencies":{"grunt":"~0.4.1"},"directories":{}},"0.1.2":{"name":"grunt-image-resize","version":"0.1.2","keywords":["gruntplugin"],"author":{"url":"http://excellenteasy.com","name":"David Pfahler","email":"david@excellenteasy.com"},"_id":"grunt-image-resize@0.1.2","maintainers":[{"name":"excellenteasy","email":"info@excellenteasy.com"}],"homepage":"https://github.com/excellenteasy/grunt-image-resize","bugs":{"url":"https://github.com/excellenteasy/grunt-image-resize/issues"},"dist":{"shasum":"b2cb98778f88cb469ca5fecc4f9cfeb81d2dc498","tarball":"https://registry.npmjs.org/grunt-image-resize/-/grunt-image-resize-0.1.2.tgz","integrity":"sha512-SlIkPJqR4UnTi4pGQszIb/I2pkq7pR63vouRKm/C4uOJ+4XoGSjgTmnhu0zpvcT5tBJAJb5aixbRaq3zwhILHw==","signatures":[{"sig":"MEQCICri/eBmQ+VksG+XKWV9aES1TNUsfXUA+L8QmLVNb7OeAiAvh8XD8TjDOeeR38aBJDLcblIiiJlW/Ynw98TsYwRlHg==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"Gruntfile.js","engines":{"node":">= 0.8.0"},"scripts":{"test":"grunt test"},"_npmUser":{"name":"excellenteasy","email":"info@excellenteasy.com"},"licenses":[{"url":"https://github.com/excellenteasy/grunt-image-resize/blob/master/LICENSE-MIT","type":"MIT"}],"repository":{"url":"git://github.com/excellenteasy/grunt-image-resize","type":"git"},"_npmVersion":"1.1.49","description":"Resizing images made easy.","dependencies":{"async":"~0.2.8","node-imagemagick":"~0.1.8"},"devDependencies":{"grunt":"~0.4.1","grunt-contrib-clean":"~0.4.0","grunt-contrib-jshint":"~0.1.1","grunt-contrib-nodeunit":"~0.1.2"},"peerDependencies":{"grunt":"~0.4.1"},"directories":{}},"0.1.3":{"name":"grunt-image-resize","version":"0.1.3","keywords":["gruntplugin"],"author":{"url":"http://excellenteasy.com","name":"David Pfahler","email":"david@excellenteasy.com"},"_id":"grunt-image-resize@0.1.3","maintainers":[{"name":"excellenteasy","email":"info@excellenteasy.com"}],"homepage":"https://github.com/excellenteasy/grunt-image-resize","bugs":{"url":"https://github.com/excellenteasy/grunt-image-resize/issues"},"dist":{"shasum":"7c216d09506c3a11c074da8ae66c0ce3ecaf10e7","tarball":"https://registry.npmjs.org/grunt-image-resize/-/grunt-image-resize-0.1.3.tgz","integrity":"sha512-/cMXys6lIfYXCz6T52T7x1e0uGB3PWoiGRcPaP57mjC/8roS1IH6CoBUKEHAr68c17u6uQ/9qCtzEY9lcWaN7Q==","signatures":[{"sig":"MEQCIBBaBb344J6BZc5S2txPm19UFvILMStnMiTNWRaWSTbeAiAlit1VwPD2yjSh+MLRb/be/FsPMcS7t0UDjtwQ/7/IPQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"Gruntfile.js","engines":{"node":">= 0.8.0"},"scripts":{"test":"grunt test"},"_npmUser":{"name":"excellenteasy","email":"info@excellenteasy.com"},"licenses":[{"url":"https://github.com/excellenteasy/grunt-image-resize/blob/master/LICENSE-MIT","type":"MIT"}],"repository":{"url":"git://github.com/excellenteasy/grunt-image-resize","type":"git"},"_npmVersion":"1.1.49","description":"Resizing images made easy.","dependencies":{"async":"~0.2.8","node-imagemagick":"~0.1.8"},"devDependencies":{"grunt":"~0.4.1","grunt-contrib-clean":"~0.4.0","grunt-contrib-jshint":"~0.1.1","grunt-contrib-nodeunit":"~0.1.2"},"peerDependencies":{"grunt":"~0.4.1"},"directories":{}},"0.2.0":{"name":"grunt-image-resize","version":"0.2.0","keywords":["gruntplugin"],"author":{"url":"http://excellenteasy.com","name":"David Pfahler","email":"david@excellenteasy.com"},"_id":"grunt-image-resize@0.2.0","maintainers":[{"name":"excellenteasy","email":"info@excellenteasy.com"}],"homepage":"https://github.com/excellenteasy/grunt-image-resize","bugs":{"url":"https://github.com/excellenteasy/grunt-image-resize/issues"},"dist":{"shasum":"36ca2c44cbf8a354e9c25e47e0f91f7c6fe9031e","tarball":"https://registry.npmjs.org/grunt-image-resize/-/grunt-image-resize-0.2.0.tgz","integrity":"sha512-NGBHKfVXfXSTDdAKLCR0X0gF0b/iUM3yPw+qXP+mlDuyiUCcjYSxQK+fYUhtvBTqM9Lzv42XKv3VGS1MEcc57g==","signatures":[{"sig":"MEYCIQDNn39lyMzGbY2iUUQhSoHRIvuGz4m2hx4Y4yAO9aG6qgIhAIqMgTB3zK/8elUEV1KVJQ5Cb7dWO8OmEMDyX7Ko0rHi","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"Gruntfile.js","engines":{"node":">= 0.8.0"},"scripts":{"test":"grunt test"},"_npmUser":{"name":"excellenteasy","email":"info@excellenteasy.com"},"licenses":[{"url":"https://github.com/excellenteasy/grunt-image-resize/blob/master/LICENSE-MIT","type":"MIT"}],"repository":{"url":"git://github.com/excellenteasy/grunt-image-resize","type":"git"},"_npmVersion":"1.1.49","description":"Resizing images made easy.","dependencies":{"async":"~0.2.8","node-imagemagick":"~0.1.8"},"devDependencies":{"grunt":"~0.4.1","grunt-contrib-clean":"~0.4.0","grunt-contrib-jshint":"~0.1.1","grunt-contrib-nodeunit":"~0.1.2"},"peerDependencies":{"grunt":"~0.4.1"},"directories":{}},"0.3.0":{"name":"grunt-image-resize","version":"0.3.0","keywords":["gruntplugin"],"author":{"url":"http://excellenteasy.com","name":"David Pfahler","email":"david@excellenteasy.com"},"_id":"grunt-image-resize@0.3.0","maintainers":[{"name":"excellenteasy","email":"info@excellenteasy.com"}],"homepage":"https://github.com/excellenteasy/grunt-image-resize","bugs":{"url":"https://github.com/excellenteasy/grunt-image-resize/issues"},"dist":{"shasum":"f680e8c47828f57b9f945bd098bcc1dc88adb8c4","tarball":"https://registry.npmjs.org/grunt-image-resize/-/grunt-image-resize-0.3.0.tgz","integrity":"sha512-5u6FO4FHgY+qg/yfu4jEV7i4jcx+hgsG9/JJJRM6HkaGK25P+VP14DZancujm8a736+eiabaAkgu+Tsy0tLxUA==","signatures":[{"sig":"MEYCIQDV7G49pBe55bPEHQLwMXdrV87DF9eZf1rTqHc+rRXt0QIhAIdYeidu+/beS/GirAIaqtn1pUyw5y09JlP6zKDOpIl0","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"Gruntfile.js","_from":".","engines":{"node":">= 0.8.0"},"scripts":{"test":"grunt test"},"_npmUser":{"name":"excellenteasy","email":"info@excellenteasy.com"},"licenses":[{"url":"https://github.com/excellenteasy/grunt-image-resize/blob/master/LICENSE-MIT","type":"MIT"}],"repository":{"url":"git://github.com/excellenteasy/grunt-image-resize","type":"git"},"_npmVersion":"1.3.11","description":"Resizing images made easy.","dependencies":{"gm":"~1.13.3","async":"~0.2.8"},"devDependencies":{"grunt":"~0.4.1","grunt-contrib-clean":"~0.4.0","grunt-contrib-jshint":"~0.1.1","grunt-contrib-nodeunit":"~0.1.2"},"peerDependencies":{"grunt":"~0.4.1"},"directories":{}},"0.4.0":{"name":"grunt-image-resize","version":"0.4.0","keywords":["gruntplugin"],"author":{"url":"http://excellenteasy.com","name":"David Pfahler","email":"david@excellenteasy.com"},"_id":"grunt-image-resize@0.4.0","maintainers":[{"name":"excellenteasy","email":"info@excellenteasy.com"}],"homepage":"https://github.com/excellenteasy/grunt-image-resize","bugs":{"url":"https://github.com/excellenteasy/grunt-image-resize/issues"},"dist":{"shasum":"07b31f219501b8a735be21a80c8bd424f15a9a25","tarball":"https://registry.npmjs.org/grunt-image-resize/-/grunt-image-resize-0.4.0.tgz","integrity":"sha512-3Ie1kMiM6h1CCb4IcpC4ujhmzmgA8zOKu46qhZk6Iu06/d2lpLK+3q6Yyd6WDdUgl/qZvsC0ol61vEh49iyYZA==","signatures":[{"sig":"MEUCIQCseRz3Siebwe3vX6R/EEH4M1r0etPCIYgbgvWyMeI8MwIgWwWqP+GwOZjhOco2w5uiWaeeEjugfWEDkc7wh+xbvDE=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"Gruntfile.js","_from":".","_shasum":"07b31f219501b8a735be21a80c8bd424f15a9a25","engines":{"node":">= 0.8.0"},"gitHead":"76874aeae20b51ccc5941408d771147498becf78","scripts":{"test":"grunt test"},"_npmUser":{"name":"excellenteasy","email":"info@excellenteasy.com"},"licenses":[{"url":"https://github.com/excellenteasy/grunt-image-resize/blob/master/LICENSE","type":"MIT"}],"repository":{"url":"git://github.com/excellenteasy/grunt-image-resize","type":"git"},"_npmVersion":"1.4.23","description":"Resizing images made easy.","dependencies":{"gm":"^1.14.2","async":"^0.2.8"},"devDependencies":{"grunt":"^0.4.5","load-grunt-tasks":"^0.6.0","grunt-contrib-clean":"^0.4.0","grunt-contrib-jshint":"^0.1.1","grunt-contrib-nodeunit":"^0.1.2","grunt-semantic-release":"^0.2.1"},"peerDependencies":{"grunt":"^0.4.5"},"directories":{}},"1.0.0":{"name":"grunt-image-resize","version":"1.0.0","keywords":["gruntplugin"],"author":{"url":"http://excellenteasy.com","name":"David Pfahler","email":"david@excellenteasy.com"},"_id":"grunt-image-resize@1.0.0","maintainers":[{"name":"excellenteasy","email":"info@excellenteasy.com"},{"name":"boennemann","email":"stephan@boennemann.me"},{"name":"davidpfahler","email":"david@excellenteasy.com"}],"homepage":"https://github.com/excellenteasy/grunt-image-resize","bugs":{"url":"https://github.com/excellenteasy/grunt-image-resize/issues"},"dist":{"shasum":"18bc3325fdf19cd51ea431b935c65c2af234ff80","tarball":"https://registry.npmjs.org/grunt-image-resize/-/grunt-image-resize-1.0.0.tgz","integrity":"sha512-H67c+3Jb8g5iuB3sWNjSzzV65UbSLKYkHC+avT1FUbwgOujaOfV5531Cukp6g3VJh/1sGvJeLDchKiCtEvvQyA==","signatures":[{"sig":"MEYCIQCF0kzYqKwjT5C771Mo/rUAQi4ihgFF90Yd/nJz0S+Q4QIhAMnr0Hsx9vQpF6cQOuVNu8HNt5VQUoJ856GDeBmncpx2","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"Gruntfile.js","_from":".","_shasum":"18bc3325fdf19cd51ea431b935c65c2af234ff80","engines":{"node":">= 0.8.0"},"gitHead":"51da0d14b5c954198e27158ad43149a3c376118f","scripts":{"test":"grunt test","after-deploy":"grunt after-deploy","before-deploy":"grunt before-deploy"},"_npmUser":{"name":"excellenteasy","email":"info@excellenteasy.com"},"licenses":[{"url":"https://github.com/excellenteasy/grunt-image-resize/blob/master/LICENSE","type":"MIT"}],"repository":{"url":"git://github.com/excellenteasy/grunt-image-resize","type":"git"},"_npmVersion":"1.4.28","description":"Resizing images made easy.","dependencies":{"gm":"^1.14.2","async":"^0.9.0"},"devDependencies":{"grunt":"^0.4.5","grunt-cli":"^0.1.13","load-grunt-tasks":"^2.0.0","grunt-contrib-clean":"^0.6.0","grunt-contrib-jshint":"^0.10.0","grunt-contrib-nodeunit":"^0.4.1","grunt-semantic-release":"^0.2.1"},"peerDependencies":{"grunt":"^0.4.5"},"directories":{}}},"time":{"created":"2013-05-08T17:54:29.285Z","modified":"2025-03-02T10:16:09.683Z","0.1.0":"2013-05-08T17:54:31.987Z","0.1.2":"2013-05-08T18:46:47.904Z","0.1.3":"2013-05-09T10:43:35.336Z","0.2.0":"2013-05-09T11:56:33.026Z","0.3.0":"2013-10-30T11:29:48.434Z","0.4.0":"2014-09-05T10:46:00.683Z","1.0.0":"2015-01-18T20:38:47.000Z"},"bugs":{"url":"https://github.com/excellenteasy/grunt-image-resize/issues"},"author":{"url":"http://excellenteasy.com","name":"David Pfahler","email":"david@excellenteasy.com"},"homepage":"https://github.com/excellenteasy/grunt-image-resize","keywords":["gruntplugin"],"repository":{"url":"git://github.com/excellenteasy/grunt-image-resize","type":"git"},"description":"Resizing images made easy.","maintainers":[{"name":"excellenteasy","email":"info@excellenteasy.com"},{"name":"boennemann","email":"stephan@boennemann.me"},{"name":"davidpfahler","email":"david@excellenteasy.com"}],"readme":"# grunt-image-resize\n\n[![Build Status](https://travis-ci.org/excellenteasy/grunt-image-resize.svg)](https://travis-ci.org/excellenteasy/grunt-image-resize)\n[![Dependency Status](https://david-dm.org/excellenteasy/grunt-image-resize.svg)](https://david-dm.org/excellenteasy/grunt-image-resize)\n[![devDependency Status](https://david-dm.org/excellenteasy/grunt-image-resize/dev-status.svg)](https://david-dm.org/excellenteasy/grunt-image-resize#info=devDependencies)\n\n> Resizing images made easy - thanks to ImageMagick.\n\n## Getting Started\nThis plugin requires Grunt `^0.4.5` and ImageMagick.\n\n### Grunt\nIf you haven't used [Grunt](http://gruntjs.com/) before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](http://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:\n\n```shell\nnpm install grunt-image-resize --save-dev\n```\n\nOne the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:\n\n```js\ngrunt.loadNpmTasks('grunt-image-resize');\n```\n\n### ImageMagick\nMake sure ImageMagick is installed on your system and properly set up in your `PATH`.\n\nUbuntu:\n\n```shell\n$ apt-get install imagemagick\n```\n\nMac OS X (using [Homebrew](http://brew.sh/)):\n\n```shell\n$ brew install imagemagick\n```\n\nWindows & others: \n\n[http://www.imagemagick.org/script/binary-releases.php](http://www.imagemagick.org/script/binary-releases.php)\n\nConfirm that ImageMagick is properly set up by executing `convert -help` in a terminal.\n\n## The \"image_resize\" task\n\n### Overview\nIn your project's Gruntfile, add a section named `image_resize` to the data object passed into `grunt.initConfig()`.\n\n```js\ngrunt.initConfig({\n  image_resize: {\n    options: {\n      width: 100,\n      height: 100,\n      overwrite: true\n    },\n    your_target: {\n      // Target-specific file lists and/or options go here.\n    },\n  },\n})\n```\n\n### Options\n\n#### options.width\nType: `Number`\nDefault value: `0` (only if height is defined)\n\nA number value that is passed as pixel or percentage value to imagemagick.\n\n#### options.height\nType: `Number`\nDefault value: `0` (only if width is defined)\n\nA number value that is passed as pixel or percentage value to imagemagick.\n\n#### options.overwrite\nType: `Boolean`\nDefault value: `true`\n\nDetermines whether file that already exist under this destination will be overwritten.\n\n#### options.upscale\nType: `Boolean`\nDefault value: `false`\n\nDetermines whether images will be upscaled. If set to `false` (default), image will be copied instead of resized if it would be upscaled by resizing.\n\n#### options.crop\nType: `Boolean`\nDefault value: `false`\n\nDetermines whether images will be cropped after resizing to exactly match `options.width` and `options.height`.\n\n#### options.gravity\nType: `String`\nDefault value: `Center`\nPossible values: `NorthWest`, `North`, `NorthEast`, `West`, `Center`, `East`, `SouthWest`, `South`, `SouthEast`\n\nWhen cropping images this sets the image gravity. Doesn't have any effect, if `options.crop` is `false`.\n\n#### options.concurrency\nType: `Number`\nDefault value: Number of CPUs\n\nDetermines how many resize operations are executed in parallel.\n\n#### options.quality\nType: `Number`\nDefault value: `1`\n\nDetermines the output quality of the resized image. Ranges from `0` (really bad) to `1` (almost lossless). Only applies to jpg images.\n\n#### options.autoOrient\nType: `Boolean`\nDefault value: `false`\n\nDetermines if resized image will be rotated according to EXIF information. Only applies to jpg images.\n\n### Usage Examples\n\n#### Default Options\nIn this example, the default options are used to resize an image to 100px width. So if the `test/fixtures/wikipedia.png` file has a width of 500px, the generated result would be a 100px wide `tmp/wikipedia.png`.\n\n```js\ngrunt.initConfig({\n  image_resize: {\n    resize: {\n      options: {\n        width: 100\n      },\n      files: {\n        'tmp/wikipedia.png': 'test/fixtures/wikipedia.png'\n      }\n    }\n  }\n})\n```\n\n#### Prevent overwriting\nIn this example, we prevent the destination file from being overwritten if it already exists. It the file `tmp/wikipedia.png` already exists, for example because we just ran the task configuration above, this would **not** overwrite `tmp/wikipedia.png`. The file `tmp/wikipedia.png` would still be 100px wide.\n\n```js\ngrunt.initConfig({\n  image_resize: {\n    no_overwrite: {\n      options: {\n        width: 50,\n        overwrite: false\n      },\n      files: {\n        'tmp/wikipedia.png': 'test/fixtures/wikipedia.png'\n      }\n    }\n  }\n})\n```\n\n#### Allow upscaling\nBy default, the task does not resize images which would be upscaled. It only allows downscaling. You can allow upscaling by setting the `upscale` option to `true`. Otherwise images will copied instead of resized when they would be upscaled by resizing.\n\n```js\ngrunt.initConfig({\n  image_resize: {\n    no_overwrite: {\n      options: {\n        width: 600,\n        upscale: true\n      },\n      files: {\n        'tmp/wikipedia.png': 'test/fixtures/wikipedia.png'\n      }\n    }\n  }\n})\n```\n\n#### Resize all the images in a directory\n\n```js\ngrunt.initConfig({\n  image_resize: {\n    resize: {\n      options: {\n        width: 100,\n      },\n      src: 'src/*.JPG',\n      dest: 'dest/'\n    }\n  }\n})\n```\n\n## Contributing\nIn lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using [Grunt](http://gruntjs.com/).\n","readmeFilename":"README.md","users":{"ixley":true,"aholla":true,"bommox":true,"loop1998":true,"mishelen":true,"monkeykode":true,"gho.morteza":true,"joshuahamilton":true,"sputnikenmeister":true}}