I require a program/script that will replace,copy or update file or files across multiple directories on a *nix system. All directories to be updated are nested under the /home directory.
Each dir target will be /home/USER/public_html/*
The program needs a method to allow me to select which directories to access/exclude.
As an example, if I want to replace or update every [url removed, login to view] file in 30 selected USER/Public_html directories from among 300 /Home/USER/pubic_html/index.html.
I would need to be able to select the the USER directories (no typing in of each dir), and have the program update only the [url removed, login to view] in the /public_html folder of each USER dir.
The program must allow the following file/folder operations:
1)Copy a file or files from a designated dir and place in multiple locations as decribed above.
2) Add a string or multi line strings to a single file that resides in multiple USER/sub directories.
It can add text to empty files or append string(s) starting on a newline at end of the current text in the file.
3) Search for string(s) in file(s) in multiple directories and delete or replace with naother designated string. Example: update html code on all pages in selected dir/sub directories
4) Delete a file from multiple directories
Any questions please PM me.