首页 > 代码库 > bash姿势-没有管道符执行结果相同与管道符

bash姿势-没有管道符执行结果相同与管道符

听起来比较别口:

直接看代码:

shell如下:

[root@sevck_linux ~]# </etc/passwd grep rootroot:x:0:0:root:/root:/bin/bashoperator:x:11:0:operator:/root:/sbin/nologin[root@sevck_linux ~]# cat /etc/passwd | grep rootroot:x:0:0:root:/root:/bin/bashoperator:x:11:0:operator:/root:/sbin/nologin[root@sevck_linux ~]# < <(echo this is a test) wc       1       4      15[root@sevck_linux ~]# echo this is a test | wc      1       4      15[root@sevck_linux ~]# 

 

just do it .

bash姿势-没有管道符执行结果相同与管道符