All Unix like systems will be built into the VI document editor, and other document editors will not necessarily exist.
But at the moment we use more of the Vim editor.
Vim has the ability to edit the program, can be active in font color to identify the correctness of the grammar, convenient programming.
Use Vi/vim to enter general mode
If you want to use VI to create a file named Hello.java, you can do this:
Press I to enter edit mode to start editing text
In the general mode, just press I, O, a and other characters can enter the editing mode!
In edit mode, you can find the –insert-in the status bar in the lower left corner, which is the hint that you can enter any character.
At this point, the keyboard, in addition to the [ESC] button, the other keys can be regarded as the general input button, so you can make any edits.
Press the [ESC] button back to normal mode
Well, assuming I've given him an edit in the style above, how do I get out? Yes! That's right! Just press the [ESC] button for him! Immediately you will find the –insert– in the lower left corner of the screen is missing!
In general mode, press: Wq after storage leave VI
OK, we want to archive, save and leave the command is very simple, enter ": Wq" can be saved away!
: Wq
Ok! This allows us to successfully create a test.txt file. is not very simple.
View Create File
LS can see all the files in the current directory (LS-L) can clearly see the properties of the file
Ls
Ls-l
If you want to open the code again and modify it, you can open it just as you would create it, and then you can edit it.
VI Hello.java
Linux VI Editor