Why does this winrar batch file work? and what does it mean?

hevnbnd

Limp Gawd
Joined
Nov 9, 2005
Messages
260
I need to recurse into subfolders with winrar so I use the -r switch... winrar x -r *.iso. Now when I launch this command from c:\ and it finds the file abc.iso in c:\folder1, it extracts the file to c:\ instead of c:\folder1. The names of the subfolders will be unknown so I can't specify them. I have been using this script

@echo OFF
REM Extract the content of all .iso files in the current directory
for %%f in (*.iso) do winrar x "%%f"
DEL *.iso
RMDIR AUDIO_TS

REM Perform the same in all sub-directories
for /D %%d in (*) do cd %%d && call %0 && cd ..


This works but I was wondering if there was a way to do it using just winrar commands? I pieced this script together from different places and honestly don't know what half the stuff means. like %%F or the whole line for /D %%d in (*) do cd %%d && call %0 && cd ..

Any help with this would be greatly appreciated.
 
Back
Top