Linux

Image Magick

CLI magic on images should definitely be noted. Thankfully Linux is full of nice tools that make that a reality. From the creation of thumbnails and the pdf extraction to image formats to more advanced processing, ImageMagick is definitely an integral tool. Here I am simply going to list commands that I happened to come across.

Check info on convert in the official ImageMagick documentation here.

# Create thumbnails
for i in $(ls -1 | sed -e 's/\.JPG$//'); do convert -thumbnail 300 $i.JPG $i-thumb.JPG; done;
# Resize images to a preset width
for i in $(ls -1 | sed -e 's/\.JPG$//'); do convert -resize 2000 $i.JPG $i-rsz.JPG; done;