Linux practical operation-aliases are permanent, line numbers are permanently displayed, hidden characters are shown, shortcuts quickly open terminal terminals
This article mainly introduces the practical simple operation of Linux to speed up the efficiency of doing things.
1. Aliases take effect forever
Add a line to vim / etc/bashrc that is alias clockwise clear`
After that, if you use source / etc/profile to take effect immediately, or reopen terminal
two。 Permanently set the line number of the vim editor
Add set nu or set number to vim / etc/vimrc (cancel and write set nu! Or set unnu)
Then source / etc/vimrc will take effect immediately.
3. Show hidden characters in the vim editor
Write: set list in the last line mode and you can see that there is a "$" symbol at the end, which is why there are more tests on wc-c than expected.
[root@localhost ~] # echo 'hello worldview' > 1.txt [root@localhost ~] # wc-c 1.txt 13 1.txt
Of course, you can write set nolist if you need to cancel.
4. Set the shortcut key to open the terminal terminal
(1) the settings in redhat6 are shown in the following figure:
(2) the settings in Centos7 are shown in the following figure