faqts : Computers : Operating Systems : Linux : Shell Commands

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

11 of 14 people (79%) answered Yes
Recently 7 of 10 people (70%) answered Yes

Entry

Is there a command that either works with grep or by itself that performs search/replace function on text files?

Oct 29th, 2000 02:29
Thomas Bader, Richard Heyes,


Yes, there are some. You could use sed, awk or perl. I recommend sed 
for basically operations.
For further information about sed:
 http://www.math.fu-berlin.de/~guckes/sed/
 http://www.gnu.org/software/sed/
 http://www.gnu.org/manual/sed/index.html
 man sed ;-)
For further information about awk:
  http://www.math.fu-berlin.de/~guckes/awk/
  http://www.gnu.org/software/gawk/
  http://www.gnu.org/manual/gawk/index.html
  man awk ;-)