-p iterates over every line in a file. So you should change
the line separator if you want this to work. Try this:
perl -0 -p -i~ -e ‘s/\n\n/\n/g’ *.java
···
On Sat, 2003-12-20 at 21:06, Xah Lee wrote:
Now may i ask those who wallow in unix and perl: How do you do this?
–
o=lambda{|o|p o};O=Struct.new(:a,:b,:c);e=%q((?h,(?h,(?\ ,(?s,(?u,(74)),
(?t)),(?t,(?o,(?n,(?a))))),(82,(?r,(?e),(32)),(32,(98,(?u),(?y)))
)),(?r,(99,(97),(?k,nil,(?e))),_(10))));def _(*a)O.new(*a)end;class O;def
e(&o)b&&b.e(&o);o[a];c&&c.e(&o)end;end;def p(o)print(‘’<<o)end;eval(e).e(&o)