On Mon, 2004-10-11 at 16:23, Urs Wagner wrote: > Hello > > I should comment out lines in a text file. I have a lot of troubles to > realize this. > > The lines > Alpha(a, b, c) > should be changed to > # Alpha(a, b, c) >
perl -pli.BAK -e 's/(?=.*Alpha\(a, b ,c\))/#/' FILENAME HTH Ram -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>