In a windows batch file, is there a way to traverse a folder/subfolders hierarchy doing some action on each file?
相关问题
- Inheritance impossible in Windows Runtime Componen
- how to get running process information in java?
- Is TWebBrowser dependant on IE version?
- How can I have a python script safely exit itself?
- I want to trace logs using a Macro multi parameter
相关文章
- 如何让cmd.exe 执行 UNICODE 文本格式的批处理?
- 怎么把Windows开机按钮通过修改注册表指向我自己的程序
- Warning : HTML 1300 Navigation occured?
- Bundling the Windows Mono runtime with an applicat
- Windows 8.1 How to fix this obsolete code?
- CosmosDB emulator can't start since port is al
- How to print to stdout from Python script with .py
- Determine if an executable (or library) is 32 -or
You can use the
FOR
command with the/r
switch, which will walk the directory tree executing whatever you specify in theDO
statement on each directory. There you can nest anotherFOR
statement, using adir /b *.*
in theSET
block.Yes, you can do this using the
for
command with the/r
switch, e.g.:See also this question for an example.
Fortunately I have quite similar purpose regarding this thread. I believe INSTRUCTION
will produce DIRECTORY TREE as result
But I want result as below
So, this SCRIPT is BORN :)
Brighter ideas are welcome. :)
That should give the same results regardless of the path depth