I have been having issues with the page speed of my site, and after a lot of research i am hoping Image Magick will sort it out.
I want to bulk convert lots of images in one folder then export all the images into an output folder folder.
Is this possible with a shell script? ie: Loop through all images from /input run the script below then output the optimised images in /output?
Here is what I have so far but this is doing one image at a time:
Code: Select all
convert /Users/bob/Desktop/image-magick/santorini.jpg -sampling-factor 4:2:0 -strip -quality 75 -resize 700x466! -interlace JPEG -colorspace RGB -background white -flatten /Users/bob/Desktop/image-magick/final/santorini-opt.jpg
https://gtmetrix.com/reports/www.tinker ... m/ac0dMCTe
Any help would be great. I am very new to this, so if there is also anything I am missing or should add/remove to my script please let me know.
I am using command line on a mac.
Thanks
Paul