(Disclaimer: This article is for Linux users such as Ubuntu)
Three modes used by VIM:
1. General Instruction Mode
2. Edit mode
3. Instruction-column Command mode
Vim's easy steps to walk:
Simple command: (I think it's better for beginners to put it in front)
Ctrl+d Show all commands for the current initials (this works)
<TAB> command Pang (better use, write the first few letters directly TAB to help you fill up the content you want to write)
:!ls or:!dir View files that exist in the current directory
: E Back to start directory
Help user-manual don't know.
Direction: H, J, K, L, left up and down right (or directly press the keyboard direction key can also)
Insert class: I current cursor insertion
: q! Discard Current Changes
: Wq save File and exit
: Vim file edits the specified file using the VIM editor
Commands and objects: operator + action
Delete class: D delete operator
: DW Deletes the current word to the next word (both the line and the line start at the cursor)
: De deletes this word
: Delete from head to tail, whole line
Search Class Command:
/+ String lookup (reverse lookup)? + string
% pair Brace Lookup
Use Count to specify an action: Entering a number before the action causes it to repeat multiple times
Input: 2w Move the cursor forward two words
3e move the cursor forward to the end of the third word
0 move the cursor to the beginning of the line
Operator class:
: E causes the current cursor to move to the end of the word
: Y copy text
: P Pastes the previously copied text
Set command options:
: set+ content, setting content
Replace command:
: s/old/new/g can replace old to new
To create a startup script:
1.:EDIT-/.VIMRC Edit VIMRC File
2.:r $vimruntime/vimrc--example.vim Reading sample files
3.:write Saving files
To delete a file:
!RM Test Delete test file
This is a study of vim after the summary and record of the section, the detailed section please check the VIM documentation, there are deficiencies please feel free, but do not like to spray!
vim--'s beginner to take a few steps