From: Florian Frank Date: 2003-12-21T06:31:12+09:00 Subject: Re: replacing two EOL chars by one On Sat, 2003-12-20 at 22:19, Zach Dennis wrote: > Shouldn't this be posted on a perl list, unless say we all gave Ruby answers > like Bill. =) Ok, but it's really not too much work to translate this from perl: ruby -0777 -p -i~ -e 'gsub(/\n\n/, "\n")' -- 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(''<