Skip to content

Instantly share code, notes, and snippets.

@luciovilla
Created August 1, 2016 19:21
Show Gist options
  • Save luciovilla/33c503605fcf8aa7e4f93705f2b708e4 to your computer and use it in GitHub Desktop.
Save luciovilla/33c503605fcf8aa7e4f93705f2b708e4 to your computer and use it in GitHub Desktop.
Useful imagemagick commands for newsrooms

Useful ImageMagick commands for newsrooms

Quickly create, edit, compose or convert images from the command line.

www.imagemagick.org

Installing

$ brew install imagemagick

Commands

convert image to width of 200, make it progresseive and reduce quality to 80%

$ convert -resize 200 -interlace Plane -quality 80

Run the same command above but for all images in a directory

$ for i in *.jpg; do convert -resize 200 -interlace Plane -quality 80 $i $i; done

More to come

Here is the site of all the commands: http://www.imagemagick.org/script/command-line-options.php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment