VI Program Editor

Source: Internet
Author: User


One of the commonly used editors under Linux is VI.


VI There are basically 3 modes available: General mode, edit mode, command line mode.




1) General mode

VI open a file directly into the general mode, the default is the general mode.

In general mode, we can use the left and right keys to move the cursor, to achieve viewing, you can delete the characters or delete the whole line, we can also copy and paste the file data. In general mode, press ": Wq" to save and leave.


2) Edit mode

VI after opening the file, press I, O, A, R (uppercase and lowercase) to enter edit mode. Insert or replace appears at the bottom left of the interface and can be edited. Pressing ESC will exit edit mode and return to normal mode.


3) command-line mode

VI into the general mode, press:/? Any one of these 3 characters enters the command line mode and the cursor moves to the bottom row. In this mode, we can find data, read, save, replace characters. pressing ESC will exit edit mode and return to normal mode.


Note: There is no switch between edit mode and command line mode.







VI Program Editor

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.