例子:
test.txt内容:
i am two old.
i come from hunan.
mhis goods.
管道登场了
cat
test
.txt|
grep
-n
'mh'
运行命令输出如下结果
mhis goods
#读出test.sh文件内容,通过管道转发给grep 作为输入内容
例子:
test.txt内容:
i am two old.
i come from hunan.
mhis goods.
管道登场了
cat
test
.txt|
grep
-n
'mh'
运行命令输出如下结果
mhis goods
#读出test.sh文件内容,通过管道转发给grep 作为输入内容