So... Ive had much luck with searching and replacing, however I cant figure 
out how to replace
thumbs/
with m
find ./*.html -type f | xargs perl -p -i.orig -e \ 's/thumbs/m/gi'
leaves me with:
<img src="m
where I want:
<img src="m1.jpg" blah blah blah

I even tried 
find ./*.html -type f | xargs perl -p -i.orig -e \ 's/thumbs//m/gi'
but ofcoures it squeeled at me... I also tried replacing /'s with "'s 
(quotes), so... anyone know how to use s/ and include /'s as part of the 
search/replace string?

Jamie

Sometime just before Monday 29 April 2002 09:34 am Bob Miller Wrote
about:[EUG-LUG:2471] Re: asynchronous file access: ? use chattr +S ?g
: Linux Rocks ! wrote:
: > : Note the "s" character at the end.  It makes the whole thing
: > : work even if the tag spans multiple lines.
:
: Oops.  I forgot -- to read the whole file into the string, you need
: this at the beginning of the perl script.  See the perlvar man page
: for details.
:
:       BEGIN { undef $/ }
:
: So the whole thing would be...
:
: >     find /var/www/htdoc -type f | xargs perl -p -i.orig -e \
: >         'BEGIN {undef $/} s/\<img [^\>]*alt=\"([^\"]*)\"/title="$1"/gis'

-- 
for setting/changing your eug-lug mailinglist subscription use this website:
http://wWw.RockSolidNetworks.com/eug-lug.html
no microsoft products were used to produce this message.

Reply via email to