Primeiramente, instale o 7-zip .
Crie um arquivo bat na raiz do diretório que contém muitos subdiretórios com arquivos dentro dele. Em seguida, cole o seguinte em:
FOR /D /r %%F in ("*") DO (
pushd %CD%
cd %%F
FOR %%X in (*.rar *.zip) DO (
"C:\Program Files-zipz.exe" x "%%X"
)
popd
)
Inicie o morcego e todos os / zips do rar serão extraídos para a pasta em que estão contidos.
Como isso funciona?
FOR /D /r %%F in ("*") DO (
For loop to loop through all folders in the current directory, and put the path into a variable
%%F.
pushd %CD%
Put the current directory that we are in into memory.
cd %%F
Set the folder from variable
%%Fas the current directory.
FOR %%X in (*.rar *.zip) DO (For all the
rarandzipfiles in the current folder, do:
"C:\Program Files-zipz.exe" x "%%X"Run 7-zip on the files. Quotes are needed around
%%Xbecause some file names have spaces in them.
popdReturn to the previous directory that we previously stored in the memory.
Espero que isso seja útil para alguém.