0

I would like to loop through some directories with pictures and copy (and after reviewing remove) them to another directory based on image dimensions, let's say smaller than 800x600.

I've tried a query like

find . -iname "*.jpg" -type f -exec identify -format '%w %h %i' '{}' \; | awk '$1<800 || $2<600

but I get no results, but I'm certain that there are smaller pictures.

Can anyone give me a hint? Thanks!

Jeff Schaller
  • 67,283
  • 35
  • 116
  • 255
wtrdk
  • 1

0 Answers0