[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Edlug Archive Mar 2004
]
[edlug] Global Search and Replace
See the sed FAQ at:
http://www.faqs.org/faqs/editor-faq/sed/
In particular the Perl solution 4.4.1.
L.
Peter George writes:
>
>
>
> Hello, one of my awful grep/fiind/regexp/vim type questions again I'm afraid.
>
> I want to search every .html file in a series of nested directories, for '</body>' and replace it with the following code snippet saving all files automagically.
>
> Is there an easy way to do this with a shell, or should I stick to EditPad or BBEdit?
>
> <!-- Start of StatCounter Code -->
> <script type="text/javascript" language="javascript">
> <!--
> var sc_project=255398;
> var sc_invisible=1;
> //-->
> </script>
>
> <script type="text/javascript" language="javascript" src="http://www.statcounter.com/counter/counter.js"></script><noscript><div class="statcounter"><a class="statcounter" href="http://www.statcounter.com"><img class="statcounter" src="http://c1.statcounter.com/counter.php?sc_project=255398&java=0" alt="site stats" /></a></div></noscript>
> <!-- End of StatCounter Code -->
> </body>
>
>
> TIA
>
>
> P
>
-
----------------------------------------------------------------------
You can find the EdLUG mailing list FAQ list at:
http://www.edlug.org.uk/list_faq.html