A folder contains 30-50 subfolders generated on a daily basis, each subfolder contains more than 10-20 files of .html.gz files format. we have to manually convert the .html.gz file to .html format on a daily basis available in all the sub folders.
the procedure we are following is
copying all the .gz files into the temp folders
mkdir temp
cp *.* temp
gunzip *.gz
moving the .html to the sub folder
for i in `ls -1`
do
mv $i $i.html
done
goto created temp folder
move all those *.gz files to previous directory and then check for that subfolder is having .html files and *.gz file
Repeat the same for all subfolders in a directory and check for next main directory.
As this is taking more time to do for all the subfolders.
Can some please write a script to do this activity . Please do the needful