我有一系列命令 a,b,c 与 &&: 链接在一起a && b && c。
a && b && c
我想将所有命令的输出都捕获到 stdout 和 stderr。 a && b && c 2>&1 > capture_file 只捕获 c 命令的输出。
a && b && c 2>&1 > capture_file
shell io-redirection
io-redirection ×1
shell ×1