help needed with 2 small scripts
by tb222 from LinuxQuestions.org on (#59J61)
Dear Community
I am looking for two small shell scripts to manage folders with fotos and pictures. As I dont have a lot of experience with scripting, I hope to find help here.
Script 1:
Folder A, contains Pictures (jpg, png etc) and other file formats.
The script should go through all the subfolders in Folder A and look for Pictures. all those pictures should be resized by X% and saved in the same folder structure in folder B. All the other files (videos, txt etc) should be copied from folder A to folder B without modification.
I will then manually delete some pictures in Folder B.
Script 2:
The script should compare Folder A with Folder B and MOVE all files that exist in Folder A but not in Folder B to a new folder C.
the final state should then be, that folder A and B contain the same files, but in different file seize for the pictures and folder C will contain all the original pictures from folder A that were deleted in Folder B.
Thank you already so much for your help. Looking forward to your answers and hope to learn something :)
chris


I am looking for two small shell scripts to manage folders with fotos and pictures. As I dont have a lot of experience with scripting, I hope to find help here.
Script 1:
Folder A, contains Pictures (jpg, png etc) and other file formats.
The script should go through all the subfolders in Folder A and look for Pictures. all those pictures should be resized by X% and saved in the same folder structure in folder B. All the other files (videos, txt etc) should be copied from folder A to folder B without modification.
I will then manually delete some pictures in Folder B.
Script 2:
The script should compare Folder A with Folder B and MOVE all files that exist in Folder A but not in Folder B to a new folder C.
the final state should then be, that folder A and B contain the same files, but in different file seize for the pictures and folder C will contain all the original pictures from folder A that were deleted in Folder B.
Thank you already so much for your help. Looking forward to your answers and hope to learn something :)
chris