This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Mail search problem.



> may be easier said than done. Perhaps the best way to do this naturally is
> to insert <meta name="robots" content="noindex,follow"> into the indexes.
> But this doesn't help older indexes unless someone does it by hand.

cd index_directory
find . -type f -name 'something*matching*index*files'| xargs -i \
echo perl -e \'undef \$/;\$_=\<stdin\>\;s/\<titl/\<meta name=\"robots\"
content=\"noindex,follow\"\>\<\\/titl/i\;\
print \$_ \' \< {} \> {}.tmp \; mv {}.tmp {} | sh

Naturally one would want to do this in a scratch directory before
turning it loose on the real files, to work out any escaping/quoting
problems that I left in;

leave off the final pipe through sh until it all looks right







________________________________________________________________________
  David Nicol 816.235.1187 UMKC Network Operations david@news.umkc.edu
           "The more wailing, the better" -- David B. Luby


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]