sed application?

Inizio della pagina
Allegati:
Messaggio come e-mail
+ (text/plain)
Delete this message
Reply to this message
Autore: Mike Starke
Data:  
Oggetto: sed application?
I have a case where I need to change the value
of a variable in a number of Perl scripts.

How would I take the results of a grep command
and apply a change to it? For instance, if I
issue the command:

'grep -r smtp_addr *'

and get a bunch of results like:

1stfile: $smtp_adrr = "old_value";
2ndfile: $smtp_adrr = "old_value";
3rdfile: $smtp_adrr = "old_value";
4thfile: $smtp_adrr = "old_value";

v/r
-Mike