Solved Compression of Tree Folder directory

October 8, 2020 at 21:10:23
Specs: Windows 10
I am not a programmer nor I know about programming, so far. The directory tree is as follows:

work/documents/Client_01/year 2018/January/PO_0001/
work/documents/Client_01/year 2018/February/PO_0002/
work/documents/Client_01/year 2018/December/PO_0092/
work/documents/Client_02/year 2019/January/PO_0001/
work/documents/Client_02/year 2019/February/PO_0002/
work/documents/Client_01/year 2019/November/PO_0012/
work/documents/Client_01/year 2019/November/PO_0032/
work/documents/Client_99/year 2020/January/PO_0001/
work/documents/Client_99/year 2020/February/PO_0002/
work/documents/Client_99/year 2020/March/PO_0005/
work/documents/Client_99/year 2020/April/PO_0031/

I have a directory tree that, almost at the end of it, has folders named as months. I want to compress all the content inside the folders that are named January, February, March, etc from of all my client's folders in Windows 10 with Winrar or 7zip. Can you help me?


See More: Compression of Tree Folder directory


#1
October 11, 2020 at 05:57:39
✔ Best Answer
:: The path delimiter is \ not /
::
::======  script starts here  ===============
:: 
:: month.bat  2020-10-11 19:33:19.97
@echo off & setLocal enableDELAYedeXpansioN
:: change this to fit your tree:
pushd d:\temp
:: add the other months here:
for %%a in ( April May ) do (
pushd %%a
start /wait 7z a %%a
popd
)
goto :eof

=====================

M2


Reply ↓  Report •
Related Solutions


Ask Question