Re: commenting all lines with a particular substring





Probably sed, awk, perl, or ruby. If you provided more information and some
sample input and expected output, we could probably help you more.

        Ed.

I Want to insert "//" at the begining of all lines which have keyword
MY_NAME in all files in all subfolders of a folder.

e.g lines in a file earlier will be
MY_NAME +=10;
a=10;

after running command it would be
//MY_NAME +=10;
a=10;

thanks,
.



Relevant Pages

  • Re: Ruby vs. PHP
    ... done is checked out which versions of Perl, Python, YARV, Ruby, jRuby ... dynamic language to the seconds for the benchmark with gcc. ... YARV, Python, Perl and PHP have fairly close medians and the boxes are ...
    (comp.lang.ruby)
  • A crosspost from the Perl Community
    ... I've been thinking of myself as a Perl developer for the past several ... and recently was handed a Ruby project. ... or an introduction of Ruby for Perl programmers. ... It's those same developers that can ...
    (comp.lang.ruby)
  • Re: For performance, write it in C - Part 2, comparing C, Ruby and Java
    ... knowing Perl is helping in my learning of Ruby. ... let's just say I think Ruby is a vast improvement on Perl. ... Frankly, I think one of the biggest reasons Java and, to a slightly ... Language" sense of entitlement -- not universally, ...
    (comp.lang.ruby)
  • Re: Why I never got into Lisp
    ... that Perl is actually the language I have the most experience with). ... I found both the CL and Ruby solutions used considerably ... But just like I did with my first Ruby approach, ...
    (comp.lang.lisp)
  • Re: A couple of questions from a Ruby neophyte
    ... Ruby has the One-click installer, which you can get from www.rubyforge.org ... Perl and Python have ActiveState versions of the same. ... Perl has the best regexp engine, ...
    (comp.lang.ruby)