Friday, May 29, 2009

Resize image files

Here is a shell script using which you can resize image files in Linux. You can use convert command for this :-

Copy the following lines to a shell script - say resize.sh

for x in $( ls *.JPG)
do
echo $x
convert -geometry 640x480 $x small-$x
done

Now execute resize.sh in the directory that contain the image files.

No comments: