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!