Shell Script, iterating over a folder
- by Martin
I have very basic shell scripting knowledge.
I have photos under original folder on many different folder like this
folder
+ folder1
+ original
+ folder2
+ original
+ folder3
+ original
+ folder4
+ original
Using mogrify I'm trying to create thumbs under a thumb folder following a structure to this.
folder
+ folder1
+ original
+ thumb
+ folder2
+ original
+ thumb
+ folder3
+ original
+ thumb
+ folder4
+ original
+ thumb
I'm a little lost in how to write the shell script that may iterate through it. I'm ok giving mogrify its settings but I don't complete understand how to tell the script to go iterate each folder to run the mogrify command.