Vim's frequently used shortcut keys

Source: Internet
Author: User

This shortcut key is used in command-line mode:

I means go into edit mode and operate at the cursor location.

YY Copy the contents of the line where the cursor is

5yy the contents of the next 5 rows, including the line where the cursor is copied

P (lowercase) paste to the next line of the cursor

P (uppercase) pasted to the previous line of the cursor

3p Paste as many times as paste 3 times

DD Delete/Cut the contents of all rows of the cursor

3dd means to delete the contents of the next 3 rows, including the cursor.

DG Delete content from the line where the cursor begins to the end of the file

O (Small letter O) Insert a blank line below the line and enter edit mode

O (capital letter O) Insert a blank line above the current line and enter edit mode

C (capital letter C) Delete the cursor position to the end of the line and enter edit mode

A quickly arrives at the end of the line and enters edit mode

Vim's frequently used shortcut keys

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.