Batch resize Images on Linux

Today I learnt another reason to stay with Linux and why something are better done in a command line Interface .
Before some windows Evangelist comes up to me and tries to sell windows by saying that  “You can do a lot of stuff on Poweshell …etc” , let me clarify with this amazing article  on why some things are better done in a CLI , and why those things can only be done on a Unix Flavoured OS .

Don’t Get me Wrong I am not a Windows Hater  (I Know People in FOSS are going to Kill me for this Statement ), but I just Love Linux (Hope this saves me !).

So getting to the Topic at Hand

How to batch resize images on Linux (Ubuntu 10.10) :

Open Terminal and Navigate to the folder where the images reside and type
mogrify -resize 800 * .jpg

This resizes all images with extension ‘.jpg’ to a width of ‘800’px and any height (denoted by  ‘*’  ).

I was surprised to find that this command actually used the full power of dual core processors and Processed about 25 (12 MP) images in less than 30 sec (Just a guess , but it was fast) .

Note the resized Images were Perfect , there were no distortion or other artefacts .


As always your comments and suggestions are welcome , Please feel free to post them .


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s