Linux Vim (4)

Source: Internet
Author: User

Vim makes a lot of improvements relative to VI:
-vim support for multi-set revocation
-vim can be run across platforms
-vim Support Syntax highlighting
-vim Support Graphical interface

Three major modes of VIM:
Default mode ESC enters when command mode VI enters
Insert Mode Command mode press I enter
Last line mode when not in input mode, enter ":" to enter

Open File:

Command line mode:: q! Exit file
VIM + ABC navigates to the last line of the ABC file
Vim + number of rows ABC positioned to line X of the ABC file
VIM +/eddy ABC navigates to the first occurrence of the Eddy line in the ABC file (press N to switch to the next occurrence)
Vim AA bb cc Open AA,BB,CC these 3 files (: N into the next file,: N or: Prev into the previous file)

Common directives in the bottom row mode
: W Save
: Q exit
:! Force exit
: LS View how many files are currently open
: N goes to the next file
: 15 cursor jumps to line 15th
/xxx looking down from the current cursor XXX
? xxx looking up xx from current cursor

Common directives in command mode
-H cursor shifts left
-J cursor Move Down
-K cursor Move up
-L Cursor Right shift
-ctrl +f PAGE Down
-ctrl +b PAGE Up
-ctrl +d down Half page
-ctrl +u up 2 turn half page

DD deletes the cursor in the row
o Insert a row below the line where the cursor is located and switch to input mode
YY the copy cursor is in the row
P paste below the line where the cursor is located
P paste above the line where the cursor is located

Linux Vim (4)

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.