in reply to Re: Re: Prepending characters to lines in file
in thread Prepending characters to lines in file
Outputmy $data = <<"EOF"; I really like jellybeans of all colors and flavors pink lemonaide blue raspberry and orange marmalade are great EOF print "First try:\n"; print "> $data\n"; print "Second try:\n"; $data =~ s/^/> /mg; print "$data\n";
First try: > I really like jellybeans of all colors and flavors pink lemonaide blue raspberry and orange marmalade are great Second try: > I really like > jellybeans > of all colors > and flavors > pink lemonaide > blue raspberry > and orange marmalade > are great
-Blake
|
---|