Linux command Intro2 VI

Source: Internet
Author: User
VI cusor:

0:to the beginning of the

$: To the end of the current line

G:to the last of the file

Gg:to the beginning of the file

Delete:

Dd:delete the current line

Dg:from the current line to the end of the file

D20g:from the current line tot the 20th line of the file

d$: From the current cursor location to the end of the "current" line

D:also used to cut data

Y:use to copy data

p:used to paste data

Yy:copy the current line

:%s/line/line/g

% specifies the range of lines for the operation. %is a shortcut
Meaning from the first line to the last line.

s specifies the operation-in this case, substitution (search and
Replace).

/line/line/the search pattern and the replacement text.

G This means global

Linux command Intro2 VI

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.