我一直在寻找针对bash命令的batch-file
解决方案
for file in temp/*/*; do ... done
假设我有一个结构:
script.bat
temp
---- A
---- fileToExclude1
-------- 0
------------ SomeFile1
------------ SomeFile2
-------- 1
------------ SomeFile3
-------- 2
------------ SomeFile4
---- B
---- fileToExclude2
-------- 0
------------ SomeFile5
-------- 1
------------ SomeFile6
------------ SomeFile7
------------ SomeFile8
------------ SomeFile9
...
如何使用批处理脚本(或cmd行)中的模拟命令将文件(SomeFile1,SomeFile2,...,SomeFile9)处理为bash命令?
答案 0 :(得分:0)
根据as a comment收到的Gerhard Barnard的建议,最终的解决方案是:
for /d %i in ("temp\*") do for /d %j in (%i\*) do for %k in (%j\*) do echo %k