Sed mode space & hold Space

Source: Internet
Author: User

Pattern Space: The buffer that holds the current input line;

Hold space: As a secondary buffer, you can interact with the pattern space, but the command cannot directly act on the hold space.

As defined above, the pattern space and the hold space are two separate buffers that can be interacted with, and the command can address the pattern space but cannot address the hold space.

One, mode space:

Rows that are matched by a pattern are read into the pattern space. Used for further operations; in multiline mode,' \ n ' can be used to match any newline character in the pattern space (the result of the n command), except for the line breaks at the bottom of the single-mode space . ^ matches the first of multiple lines, $ matches the tail of multiple lines, not the beginning of each line and the end of the line.

Second, to maintain space:

You can interact with the pattern space through h,h,g,g.

Sed mode space & hold Space

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.