Raspberry Pi_Eng_10.4.1 “clear” Command – Clear Screen


Published Book on Amazon


All of IOT Starting with the Latest Raspberry Pi from Beginner to Advanced – Volume 1
All of IOT Starting with the Latest Raspberry Pi from Beginner to Advanced – Volume 2


출판된 한글판 도서


최신 라즈베리파이(Raspberry Pi)로 시작하는 사물인터넷(IOT)의 모든 것 – 초보에서 고급까지 (상)
최신 라즈베리파이(Raspberry Pi)로 시작하는 사물인터넷(IOT)의 모든 것 – 초보에서 고급까지 (하)


Original Book Contents


10.4   Basic Command

 

10.4.1  "clear" Command - Clear Screen

 

When you work on the Shell Terminal, various contents are displayed on the screen. It can be inconvenient if the content of the screen is large or complex. In this case, you want to clear the current Terminal screen and start a new one. When you want to erase all the contents of the screen and start a new one, use the following command.

 

[Command Format]

clear

 

[Command Overview]

   This clears all contents of Terminal screen.

   User privilege          -- Normal user.

 

[Detail Description]

This command does not erase the contents of the screen but move them up so that it is invisible. Therefore, when you scroll bar up, you can recall the original contents.

 

[Used Example]

When various commands are executed, the screen is full of various contents as follows.

 


 

Execute the following command while the above screen is displayed.

 

pi@raspberrypi ~/testdata $ clear

 

Then, the contents of the screen are cleaned up, and the cursor moves to the top of the screen.

 


 

Then, by moving the scrollbar up, you can view the previous display again.