The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 07-11-2006
kirrushna kirrushna is offline
Registered User
  
 

Join Date: Jul 2006
Posts: 1
Wink Finding pattern & prepending a line with text

Hello Dudes,

I have a task to make a unix shell script that should search for a
specific TEXT in a file.If that TEXT is found, shell script should add
a comment statement before that TEXT line.

Ex : LINE 1 xxxxx
LINE 2 xxxx CALL xxxx
LINE 3 xxxx PERFORM UNTIL

if i am looking for CALL as TEXT then shell script should add
comment statement after LINE 1.

Can somebody help me with that?

Thanks in advance
krishna

"Without GOD i cannot,Without ME god will not"