One feature of Linux is that there is much more powerful, and the frequent input command is not only troublesome and the workload is large. Although you can use Tab to make your own input, or use Aliase to simplify the input of a command, but this does not fundamentally fundamentally Solve the problem of too many tap keys. You can specify a combination of commands or commands to a key on the keyboard, which can be Alt [AZ], Ctrl- [AZ], Alt Shift [AZ], F1-F12, Ctrl-F [1-12], Alt-f [1-12], alt shift f [1-12], and more incredible is even if you can add "parameters" for function keys, so that you press the key, it will wait You enter the corresponding parameters and run different commands according to different parameters. Of course, some hot bonds will be captured by the terminal, such as common CTRL-D / C / Q / Z, but it doesn't matter, the hot bond available can be used! Define the configuration file of the hotkey as: / etc / inputrc or ~ / .inputrc, define the format of the hotkey as follows: "The hotkey corresponds to the ASCII characters>:"
In general, we can use the up and down direction keys to find the list of command history, repeat the input command, but the direction is too far, such as> If frequent use, will delay a lot of time, and move the right hand Not very convenient, is there any way to transfer the function of the arrow keys to us often> Knock on the command? If you use Alt J = Down Arrow to find down, Alt K = UP Arrow looks down to do this by defining hot keys: "/ eh": "^ [o" # Move Left # alt-h to left Move a character, equivalent to left arrowgh, here ^ [o 即 即 上 上 方 的 a a 字 类似 类似 类似 类似 类似 类似 类似 类似 类似 类似 类似 类似 类似 类似 类似 类似 一 类似 一Character, equivalent to Right Arrow "/ EJ": "^ [ob" # Move Up # alt-j moves down, equivalent to UP Arrow "/ ek": "^ [OA" # move down # alt-k up move , Equivalent to Down Arrow "/ EI": "^?" # Ip Earse One Character # alt-i to remove a character, equivalent to backspace "/ eo": delete-char # Right Earse One Character # alt-o Right delete a character, equivalent to delete "/ en": backward-kill-word # left kill one word # alt-n to left a word "/ em": Kill-Word # Right Kill One Word # alt-m Right Delete a word "/ EA": "^ [n ^ [n ^ [n ^ [N ^ [N ^ [N ^ [N" # kill to the head # alt-a delete the current location to the beginning, that is ALT-N (a-> ahead) "/ ee": "^ [m ^ [m ^ [m ^ [m ^ [m ^ [m ^ [M" # kill to the head # alt-e delete The current position is at the end, that is, multiple Alt-M several times (e-> end) "/ EP": insert-last-argumem "# alt-p inserts the last parameter (P -> Paste)" / eW ": Forward-Word # System Default ALT-F (Forward) Skip to the current word word, if you have already in the word, jump to the next word (one word on the right) Word" / EQ ": Backward-Word # system default Alt-b (backward) jumps to the current word word, if it is already in the word, jump to the previous word (one word on the left), the first thing of the F and B are too far, inconvenient, even respectively change ALT- Q, ALT-W, However, Alt-F / B can almost do not need to leave the main keyboard area when you enter the command, and move the cursor, delete characters, delete words, and the upper and lower historical commands look up> in one, more convenient than before. However, it will be somewhat not used to it, just like VI, but I will be skilled in recentation.
The configuration of most of Linux is based on the configuration file. Generally, change the configuration file of a service, to make it take effect, but also to restart the service directly or an attached daemon. Don't you feel that "every vi /etc/xxx.conf is also the service xxx restart / rel." Do you do this very cumbersome? If you want to configure more services, do you have to debug it? And usually use Linux, it is difficult to terminate or start a service process from time to time, and the number of input commands is also a lot. If you specify a hotkey for each service, it seems unlikely. If we give a hotkey as a basic key, the corresponding service is its "parameter", what is it? For example, give alt-s (s-> start) to start the basic key of the launch service, the first 2 characters of the service name are start "parameters", then you can start a service as follows: "/ ESSM ":" Service SMB Start / N "# / ES = alt-s, SM = SMB, # 即: Press Alt-S to follow the back SM (At this time, the input SM will not be displayed on the terminal) You can start the Samba service process, don't worry about pressing the time latency between pressing the key and the "parameter", you press Alt-S, then go back to the outside, then enter SM, so that you can.