A. Mobile: h,j,k,l: Left, bottom, top, right. W: The first word of the next word. W: Next word (without punctuation). E: The ending of the next word. E: Punctuation is not included. B: The word head of the previous word. B: Punctuation is not included. <>: The V mode is selected and then indented. Two. Jump:%: Can match {}, "", (), [] jump between. H, M, L: Jumps directly to the top, middle, and bottom of the current screen. #H: Jumps To line # of the current screen. #L: Jumps to the bottom # line of the current screen. ZT: The current edit line is placed on top of the screen. ZZ: The current edit line is placed on the screen. ZB: The current edit line is placed on the bottom of the screen. G: Jump directly to the bottom of the file. GG: Jump to the top of the file. GD: Jumps to the definition of the function and variable where the cursor is located. (): Jumps to the current beginning and end of line. {}: Jumps up and down to the nearest empty line. [{: Jump to the beginning of the current chunk.] ]}: Jumps to the end of the current chunk. 0: Jump to the beginning of the line. $: Jumps to the end of the line. 2$: Jumps to the end of the line at the next line. #: Jumps to the first # position of the line. #G: 15G, jump to line 15. : #: Jump to # line. Three. Select: 1.v: Turn on the visual mode. V: Turn on progressive visual mode. 2.^v: Rectangle selection. 3.V3W: Select three characters. 4.ab: Includes brackets and areas within (). 5.aB: Includes brackets and areas within {}. 6.ib: The area within the brackets (). 7.iB: The area within the brackets {}. 8.aw: Mark a word. Four. Edition: 1. Added: I: Insert before cursor. I: Inserted at the beginning of the current line. A: Insert after cursor. A: The current line end is inserted. O: Insert a new row before the current line. O: Inserts a new row after the current line. 2. Modify the C (change) Main: R: Replace the character at the cursor location. R: Replaces the character where the cursor is located. CW: Changes the word-to-tail at the cursor location. C#W:C3W modifies 3 characters. C: Modify to end of line. CI ': Modifies the text content in the paired punctuation. Di ': Delete the text content in the paired punctuation. Yi ': Copy the text content in the paired punctuation. VI ': Select the text content in the paired punctuation. S: replaces the character at the current cursor. #S: Delete the # line and replace it with the new text. 3. Delete main: D: Delete to the end of the line. X: Deletes the previous character in the position of the cursor every time it is pressed. X: Every time you press the cursor, delete the following character at the location of the pointer. #x: Delete the 6 characters after the cursor position. d^: Delete to the beginning of the line. d$: Delete to the end of the line. DD: (CUT) deletes the line where the cursor is located. DW: Deletes the remainder of the word after a word/cursor. D4W: Delete 4 word. #dd: Deletes the # line starting at the line where the cursor is located. DaB: Deletes the contents of {} and within it. DiB: Delete the contents of {}. N1,N2 d: Removes the content between the n1,n2 rows. 4. Find:/: Enter keywords, find not to find, directly in the press N, search backwards until found.?: Enter the keyword, find it is not looking for, directly in the N, search forward until you find it. *: Find the same word backwards on the current page. #: Finds the same word forward on the current page. 5. Copy y (Yank) to main: yw: Copies the characters from the cursor to the end of the word into the buffer. #yw: Copies the # characters to the buffer. Y: Equivalent to YY, copy the entire line. #yy: Represents the number of lines of text that is copied from the line where the cursor is located. P: Paste. All operations related to Y must be combined with p to paste. ]p: Paste to the appropriate indent. N1,N2 CO N3: Copy the contents of line N1 to section N2 to the N3 line. 6. Case conversion: GUU: Change the letter of the current line to uppercase. GUU: Changes the current line's letter to lowercase. GUW: Changes the word under the current cursor to uppercase. GUW: Changes the word under the current cursor to lowercase. A. Whole capitalization: GGGUG GG: Cursor to the first character of the file. Gu: The selection range is all lowercase. G: To the end of the file. B. Entire lowercase: gggug 7. Other: J: The current line and the next line are merged into one line. 8. Move: n1,n2 m N3: N1 line to N2 lineTo the N3 line.
Vim shortcut keys