Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: matching first paragraph satisfying condition

by 1nickt (Abbot)
on Aug 05, 2019 at 16:52 UTC ( #11103969=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $ cat foo.txt
      indented
    ...
    
    not indented
      yak
    
  2. or download this
    $ perl -Mstrict -wE '$/="";while (<>) { chomp; if (/^\w/ .. /^$/) {pri
    +nt; exit} }' < foo.txt
    not indented
      bla
    bla
      bla
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11103969]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (5)
As of 2020-01-28 20:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?