by Devin Yang
(This article was automatically translated.)

Published - 7 years ago ( Updated - 7 years ago )

How to clear the current command line in Linux or Mac terminal?
For example, if you typed a bunch of instructions wrongly, and you want to clear them,
Be sure to do the same as I used to, use the reverse key to kill slowly, we can use ctrl+u
Remove the entire command line directly.
If you press ctrl+u to delete the entire line command,
If you want to restore , you can press ctrl+y .

Tags: linux mac terminal tips

Devin Yang

Feel free to ask me, if you don't get it.:)

No Comment

Post your comment

Login is required to leave comments

Similar Stories


linux

Load the environment variables of .env to the system

Load the environment variables of .env to the system

linux

How to install the monitor tool htop on CentOS

Htop is a free (GPL) ncurses-based program monitor tool for Linux. It is similar to top, but allows you to scroll vertically and horizontally, so you can see the full command line running on the system, And you can view them as program trees, select multiple programs and operate them.

linux,macos

PS aux will you?

For Linux system administrators, you must understand the ps aux command. If you want to be a Linux system administrator, or you are a Linux user, you should understand this command. ps is process status For short, anyone can find out what kind of program is running on the system and how the status is executed through this command. I saw some programs that should not appear, maybe the system was hacked and used to mine🥹