Windows command line how to call a tool for every file in directory tree -


i have many directories many files. how call command (echo i.e.) every file?

what have done is:

for %a in (*) d:\wget>xidel.exe --extract  "//a/@href" %a > d/wget/links.txt 

it can it's job in single directory. how force process directory tree recursively?

use /r switch for command.

for /r [[drive:]path] %variable in (set) command [command-parameters]

walks directory tree rooted @ [drive:]path, executing statement in each directory of tree. if no directory specification specified after /r current directory assumed. if set single period (.) character enumerate directory tree.

so echo every filename starting in e:\temp , recursing subfolders, can use

cd /d e:\temp /r %a in (*) echo %a 

Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -