Linux基礎命令---文字便捷tee
阿新 • • 發佈:2019-01-04
tee
將標準輸入的內容複製到指定的檔案中,同時在標準輸出中顯示。
此命令的適用範圍:RedHat、RHEL、Ubuntu、CentOS、SUSE、openSUSE、Fedora。
1、語法
tee [選項] [files]
2、選項列表
--version
顯示命令版本資訊
--help
顯示幫助文件
-a | --append
追加模式,並不覆蓋
-i | --ignore-interrupts
忽略終端訊號
3、例項
將檔案內容排序之後儲存到另外的地方
[[email protected] weijie]# cat 2.c //檢視內容
hello linux
i am weijie
love world
hehe
im join
[[email protected] weijie]# sort 2.c | tee 4.c //排序之後儲存到4.c,並且送到biaozhun輸出
hehe
hello linux
i am weijie
im join
love worl
將標準輸入的內容複製到指定的檔案中,同時在標準輸出中顯示。
此命令的適用範圍:RedHat、RHEL、Ubuntu、CentOS、SUSE、openSUSE、Fedora。
1、語法
tee [選項] [files]
2、選項列表
顯示命令版本資訊
--help
顯示幫助文件
-a | --append
追加模式,並不覆蓋
-i | --ignore-interrupts
忽略終端訊號
3、例項
將檔案內容排序之後儲存到另外的地方
[[email protected] weijie]# cat 2.c //檢視內容
hello linux
i am weijie
love world
hehe
im join
[[email protected] weijie]# sort 2.c | tee 4.c //排序之後儲存到4.c,並且送到biaozhun輸出
hehe
hello linux
i am weijie
im join
love worl