bash把所有屏幕输出重定向到文件并保持屏幕输出的方法


输出到文件log中,并在屏幕上显示:
#ls >&1 | tee log

追加输出到文件log中,并在屏幕上显示:
#ls >&1 | tee -a log

posted @ 2013-11-13 11:29  emanlee  阅读(1584)  评论(0编辑  收藏  举报