Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^3: newlines in regular expressions

by eyepopslikeamosquito (Chancellor)
on Dec 07, 2004 at 07:22 UTC ( #412848=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    perl -p -e 'BEGIN { undef $/ } s/\n{2,}/\n/g'
    
  2. or download this
    perl -p0777e 's/\n{2,}/\n/g'
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2016-02-13 15:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How many photographs, souvenirs, artworks, trophies or other decorative objects are displayed in your home?





    Results (437 votes), past polls