Linux: VI shortcut

Source: Internet
Author: User

(1) flip the page to the first part of the file

A) Ctrl + B; open the first screen of the file

B) Ctrl + u: Flip the half screen to the first part of the file

(2) Turning to the end of a file

A) Ctrl + F: Turn a screen at the end of the file

B) Ctrl + D: Flip the half screen to the end of the file

(3) commands for moving the cursor

A) Move left

    1. H: move the cursor one character to the left
    2. B or B: move one word left to the beginning of the word
    3. (: Move the cursor to the beginning of the sentence.
    4. Delete before X

B) Right Shift

    1. L: move the cursor one character to the right
    2. W or W: move one word to the beginning of the word to the right of the cursor.
    3. E or E: move one word to the end of the word to the right of the cursor.
    4. Delete after X

C) Move Up

    1. K or Ctrl + P: move the cursor up a row
    2. N-: Move n rows above the cursor

D) Move down

    1. J or Ctrl + N: move the cursor down a row
    2. N +: move the cursor down n rows

E) beginning and end

(: Move the cursor to the beginning of the sentence.

): Move the cursor to the end of the sentence.

0: (Note the number is zero) move the cursor to the beginning of the current row

$: Move the cursor to the end of the current row

{: Move the cursor to the end of the paragraph

}: Move the cursor to the beginning of the paragraph

H: move the cursor to the top line of the screen

M: move the cursor to the middle line of the screen

L: move the cursor to the last line of the screen

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.