您的位置:首页 > 其它

command > filename 2>&1 把标准输出和标准错误一起重定向到一个文件中

2010-07-06 19:55 393 查看
如果你不想把一些信息打印到屏幕上可用:

command > filename 2>&1 把标准输出和标准错误一起重定向到一个文件中

See the following example

[root@se tmp]# gpg -o /tmp/hi2 --passphrase cnic252 -d hi.gpg
gpg: CAST5 encrypted data
gpg: encrypted with 1 passphrase
gpg: WARNING: message was not integrity protected

[root@se tmp]# gpg -o /tmp/hi2 --passphrase cnic252 -d hi.gpg >/dev/null 2>1

[root@se tmp]# gpg -o /tmp/hi2 --passphrase cnic252 -d hi.gpg >/dev/null 2>&1
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐