What's wrong with this batch file? It only appears to grab the first directory, instead of all subdirs. Sometimes it doesn't even do that.. f
for %%i in (*.) DO (
cd %%i
del shortlist.bbs
for %%j in (*.zip) DO (
pkunzip -o %%j file_id.diz %temp%
set /p output=<%temp%\file_id.diz
echo %%j %output%>>shortlist.bbs
)
cd ..
)
What's wrong with this batch file? It only appears to grab the first directory, instead of all subdirs. Sometimes it doesn't even do that.. f
for %%i in (*.) DO ( cd %%i del shortlist.bbs for %%j in (*.zip)
DO ( pkunzip -o %%j file_id.diz %temp% set /p
output=<%temp%\file_id.diz echo %%j %output%>>shortlist.bbs
) cd .. )
I'm sure I missed something obvious, but I can't figure it out. Can I not nest for do loops? This is to grab the first line of file_id.diz files, put the filename a few spaces, then the description into a file for
my ftp server to display descriptions. pkunzip and set are working.
It's not looping though.
set /p output=<%temp%\file_id.diz
| Sysop: | deepend | 
|---|---|
| Location: | Calgary, Alberta | 
| Users: | 281 | 
| Nodes: | 10 (0 / 10) | 
| Uptime: | 00:43:45 | 
| Calls: | 2,409 | 
| Calls today: | 2 | 
| Files: | 5,175 | 
| D/L today: | 
  				159  				files  				 (56,161K bytes)  | 
  		
| Messages: | 437,507 |