I have a directory filled with a TON of images. Probably over a million. I'm setting up a system to break the images up based on their filename. The image filenames are just numbers... 1- 500,000. And there are two images for each. A thumb and a full image.
So something like...
Not every number 1 - 500,00 is taken however. Some might be missing. So, I don't know if it's better to have the script cycle through the actual images somehow... or just to loop hard set numbers.. and if we get to a number and the file doesnt exist.. it will just skip it.
As for the directories. I set them up in a way where it's based on the number. So, image 5678.jpg. Would go into:
34.jpg would go to:
450321.jpg would go to:
so the script would have to read the filename.. or just the number that we are on and then issue a copy command based on the number. I set up the directories using this Quesion:
I think that about covers it. Anyone know of the best way to do this?