Google Answers Logo
View Question
Q: search/replace sed command ( No Answer,   1 Comment )
Subject: search/replace sed command
Category: Computers > Operating Systems
Asked by: questioner1234-ga
List Price: $3.00
Posted: 06 Mar 2005 06:13 PST
Expires: 05 Apr 2005 07:13 PDT
Question ID: 485594
I need a sed command that will search for a word X in all of the files
in a directory and subdirectory and replace them with Y. So the
command needs to look into each subdirectory and apply the
search/replace to all of the files it finds.

Request for Question Clarification by efn-ga on 06 Mar 2005 20:42 PST
sed doesn't know how to find its way through directories.  You have to
use some other technology for that.

That said, does this FAQ section answer your question satisfactorily?
There is no answer at this time.

Subject: Re: search/replace sed command
From: uoy_pleh_i_yam_woh-ga on 07 Apr 2005 23:31 PDT
I take that you are using Unix, but if you can go either way, I
believe that the tool that you are looking for is:, and it does it all, regular
expressions, multi search and replacements, command line and GUI
based, and so forth.

  Good luck.

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  

Google Home - Answers FAQ - Terms of Service - Privacy Policy