Linux shell--is expression

Source: Internet
Author: User

Regular

Grep

Match, and can display the color

filter, display line numbers, case sensitive

GREP-V Reverse

Take 2 lines, next 2 lines, two rows above and below

Lines that begin with #

Do not print the beginning of the #, for example, when looking at the configuration file can be used

Match all

Once o or more, * is 0 times O or more

? Number of repetitions 0 or 1

| Or

Case insensitive

. Any one character

* 0 or more * preceding characters

. * Pass With

{} indicates the preceding character of the range

+ one or more of the preceding characters

? 0 or 1 preceding characters

| Or

Sed

Match and replace

-N do not print unrelated lines

R No translation

Match 2~5 Line

Print 25~ last line

Print all

Match multiple, line, and keyword

Linux shell--is expression

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.