سؤال

How can i find and resize images with resolution higher that X width in unix cli? I have tried

find -name *.jpg -exec mogrify -resize 800x800 -format jpg {} \;

but the problem is that resizes also the images that have width or height below from 800 pixels.

هل كانت مفيدة؟

المحلول

I have found it. This is it:

find * -iname '*.jpg' -print0 | xargs -0 mogrify -resize 800x800\> -monitor -format jpg
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top