示例:
for /? | if (this stream has word "the" in it) {echo the line with "the"}
我需要以某种方式分析重定向流中的文本。
答案 0 :(得分:0)
http://www.febooti.com/products/command-line-email/batch-files/ms-dos-command-redirection.html
本网站提供有关您在DOS中可以做的不同类型管道的良好信息。
答案 1 :(得分:0)
使用管道,使用竖线“|”。
例如:
将的输出输出到 find :
for /? | find "the"
输出的前几行:
command Specifies the command to carry out for each file.
Specifies parameters or switches for the specified command.
To use the FOR command in a batch program, specify %%variable instead
If Command Extensions are enabled, the following additional
forms of the FOR command are supported:
If set contains wildcards, then specifies to match against directory