home products tech support contact us

 Linux 技術支援    ⇒   基礎篇    進階篇    補腦篇    指令索引    中⇒ENG
版權所有, 引用請註明出處
 

clear : Clearing the Terminal Screen

clear 清除終端機螢幕(clear the terminal screen),同 DOS 的 cls。

clear 能有效地清除了之前執行的所有命令及其輸出,以獲得一個乾淨且空白的終端視窗。當終端顯示過多輸出,您希望有一個嶄新清爽的屏幕開始時,這將特別有用。

clear 命令不需要任何參數或選項。您只需在終端中輸入clear 然後按Enter。

例:
$ echo "Hello World!" ← display〝Hello World!〞
Hello World!
$ clear ←clear the terminal screen

某些時候 clear 也無法清除螢幕,可用 reset 來重置螢幕,其範例和用法參考連結