sed with several lines, how?
hyphen's [ - ] are just for marking the start/end of a pattern, but
there are _not in_ the pattern! "OUTPUT" is what i want after "seding" the PATTERN#X's so i for e.g.: need the first, and second "magic" sed "FIRSTMAGIC" PATTERN#1 sed "SECONDMAGIC" PATTERN#2 PATTERN#1: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#2</font><br> <br><font size=3>SOMETEXT#3</font><br> SOMETEXT#4 ----------------------------------- "exact pattern", what is unique from the pattern: ----------------------------------- </font><br> <br><font size=3> ----------------------------------- OUTPUT: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#3</font><br> SOMETEXT#4 ----------------------------------- and: PATTERN#2: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#2</font><br> </font></div></body></html> SOMETEXT#3 ----------------------------------- "exact pattern", what is unique from the pattern: ----------------------------------- </font><br> </font></div></body></html> ----------------------------------- OUTPUT: ----------------------------------- SOMETEXT#1 </font></div></body></html> SOMETEXT#3 ----------------------------------- i just can't figure it out, how to "sed" when having several lines [nor in awk, perl..] could anyone post a link, or some guide, how to write these two lines of "sed"? Thank You! : _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
sed with several lines, how?
hyphen's [ - ] are just for marking the start/end of a pattern, but
there are _not in_ the pattern! "OUTPUT" is what i want after "seding" the PATTERN#X's so i for e.g.: need the first, and second "magic" sed "FIRSTMAGIC" PATTERN#1 sed "SECONDMAGIC" PATTERN#2 PATTERN#1: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#2</font><br> <br><font size=3>SOMETEXT#3</font><br> SOMETEXT#4 ----------------------------------- "exact pattern", what is unique from the pattern: ----------------------------------- </font><br> <br><font size=3> ----------------------------------- OUTPUT: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#3</font><br> SOMETEXT#4 ----------------------------------- and: PATTERN#2: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#2</font><br> </font></div></body></html> SOMETEXT#3 ----------------------------------- "exact pattern", what is unique from the pattern: ----------------------------------- </font><br> </font></div></body></html> ----------------------------------- OUTPUT: ----------------------------------- SOMETEXT#1 </font></div></body></html> SOMETEXT#3 ----------------------------------- i just can't figure it out, how to "sed" when having several lines [nor in awk, perl..] could anyone post a link, or some guide, how to write these two lines of "sed"? Thank You! : -- users mailing list users@lists.fedoraproject.org To unsubscribe or change subscription options: https://admin.fedoraproject.org/mailman/listinfo/users Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines |
sed with several lines, how?
hyphen's [ - ] are just for marking the start/end of a pattern, but
there are _not in_ the pattern! "OUTPUT" is what i want after "seding" the PATTERN#X's so i for e.g.: need the first, and second "magic" sed "FIRSTMAGIC" PATTERN#1 sed "SECONDMAGIC" PATTERN#2 PATTERN#1: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#2</font><br> <br><font size=3>SOMETEXT#3</font><br> SOMETEXT#4 ----------------------------------- "exact pattern", what is unique from the pattern: ----------------------------------- </font><br> <br><font size=3> ----------------------------------- OUTPUT: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#3</font><br> SOMETEXT#4 ----------------------------------- and: PATTERN#2: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#2</font><br> </font></div></body></html> SOMETEXT#3 ----------------------------------- "exact pattern", what is unique from the pattern: ----------------------------------- </font><br> </font></div></body></html> ----------------------------------- OUTPUT: ----------------------------------- SOMETEXT#1 </font></div></body></html> SOMETEXT#3 ----------------------------------- i just can't figure it out, how to "sed" when having several lines [nor in awk, perl..] could anyone post a link, or some guide, how to write these two lines of "sed"? Thank You! : -- To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org Archive: AANLkTinTfCzAdS7QWG4tNYQwBAmp4v42NDx6CZseLH-e@mail.gmail.com">http://lists.debian.org/AANLkTinTfCzAdS7QWG4tNYQwBAmp4v42NDx6CZseLH-e@mail.gmail.com |
sed with several lines, how?
hyphen's [ - ] are just for marking the start/end of a pattern, but
there are _not in_ the pattern! "OUTPUT" is what i want after "seding" the PATTERN#X's so i for e.g.: need the first, and second "magic" sed "FIRSTMAGIC" PATTERN#1 sed "SECONDMAGIC" PATTERN#2 PATTERN#1: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#2</font><br> <br><font size=3>SOMETEXT#3</font><br> SOMETEXT#4 ----------------------------------- "exact pattern", what is unique from the pattern: ----------------------------------- </font><br> <br><font size=3> ----------------------------------- OUTPUT: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#3</font><br> SOMETEXT#4 ----------------------------------- and: PATTERN#2: ----------------------------------- SOMETEXT#1 <br><font size=3>SOMETEXT#2</font><br> </font></div></body></html> SOMETEXT#3 ----------------------------------- "exact pattern", what is unique from the pattern: ----------------------------------- </font><br> </font></div></body></html> ----------------------------------- OUTPUT: ----------------------------------- SOMETEXT#1 </font></div></body></html> SOMETEXT#3 ----------------------------------- i just can't figure it out, how to "sed" when having several lines [nor in awk, perl..] could anyone post a link, or some guide, how to write these two lines of "sed"? Thank You! : -- ubuntu-users mailing list ubuntu-users@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users |
| All times are GMT. The time now is 04:41 AM. |
VBulletin, Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.