Latest LQ Deal: Latest LQ Deals
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 05-04-2013, 04:14 AM   #1
LQ Newbie
Registered: May 2013
Posts: 1

Rep: Reputation: Disabled
working example to create a small archive of your photos using convert (imagemagick)

First create a duplicate folder for your archive based on your orig structure (with no files).
For me /data/all_photos is where the big originals are, and i want copy put in /data/small

cd /data/all_photos
rsync -av -f"+ */" -f"- *" . /data/small
then, put this is a nice bash script (called rgm) in location say /data
{replace *123*.JPG with * or whatever you want}

while read file
  convert -monitor -resize 1024x1024 "$file" "/data/small/${oufile}"
done < <(find . -name \*123*.JPG)
just run your command with
{make sure your pwd is your photo root folder - for me /data/all_photos}

if you need convert, then get it using
sudo apt-get install imagemagick --fix-missing

Last edited by rmcknight; 05-04-2013 at 04:59 AM. Reason: added code tags
Old 05-04-2013, 04:52 AM   #2
LQ Veteran
Registered: Nov 2005
Location: London
Distribution: Slackware64-current
Posts: 5,833
Blog Entries: 1

Rep: Reputation: 1230Reputation: 1230Reputation: 1230Reputation: 1230Reputation: 1230Reputation: 1230Reputation: 1230Reputation: 1230Reputation: 1230
Hi and welcome to LQ.

Thanks for the howto. Can you please wrap your code with the code tags? It will make it so much more readable. Thanks

Last edited by sycamorex; 05-04-2013 at 04:52 AM. Reason: Forgot about the ?


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
ImageMagick convert and eps Daravon Linux - Software 7 02-16-2012 04:06 PM
[SOLVED] Using convert from imagemagick package to convert multiple jpg files janis_169 Linux - Newbie 5 07-18-2010 04:22 PM
ImageMagick-Convert, resize width, keep aspect cadj Linux - Software 2 06-18-2010 05:10 PM
ImageMagick - convert cornish Linux - Software 3 06-13-2006 08:26 AM
where would I find ImageMagick's convert program? kuplo Linux - Software 1 01-12-2006 12:00 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:18 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration