Josh (the blog)

I’ve delivered simple, clear and easy-to-use services for 20 years, for startups, scaleups and government. I write about the nerdy bits here.


@joahua

Change JPG quality in a shell

Yeah, so I’m posting the dregs of what I’m learning for another project here. Deal with it! I was rather proud of this little gem, not because it’s amazingly complicated, but just because it saves me so much time and bandwidth (think download, process locally using GUI tools, re-upload).

mogrify -geometry 700x525\> -quality 85 -unsharp 1x1 *.JPG

YMMV with the *.JPG bit… obviously will need changing. This whole thing depends on ImageMagick being installed… but it will be on most platforms (By platforms, I mean real operating systems where you don’t need a graphical display to pull these things off! *puts on seedy hardcore chain smoking Unix geek voice* “I do typesetting and print design from the console, man.”), I’d imagine.