在tee >(head) | tail < text.txt,文本文件直接进入tail.你可能意味着
tee >(head) < text.txt | tail
Run Code Online (Sandbox Code Playgroud)
哪个不等待任何东西,但也不起作用,因为T恤和头部的输出都是尾部.
将头部的输出重定向到新的文件描述符,然后将其恢复工作,但我不确定它比使用/ dev/null更"干净":
( tee >(head >&3) < text.txt | tail) 3>&1
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
2921 次 |
| 最近记录: |