Page MenuHomePhabricator
Paste P3012

search-self-closing
ActivePublic

Authored by tstarling on May 9 2016, 5:05 AM.
Tags
None
Referenced Files
F3984766: search-self-closing
May 9 2016, 5:25 AM
F3984724: search-self-closing
May 9 2016, 5:05 AM
Subscribers
None
#!/bin/bash
for wiki in `</srv/mediawiki-staging/dblists/large.dblist`;do
namespace=$(echo 'print $wgContLang->getNsText(10);' | mwscript maintenance/eval.php --wiki="$wiki" )
echo -n "$wiki | "
for tag in div span; do
echo "$namespace:insource:$tag insource:/\<$tag [^>]*\/>/" | \
mwscript extensions/CirrusSearch/maintenance/runSearch.php --wiki="$wiki" \
| php -r '$r = json_decode(stream_get_contents(STDIN)); print "{$r->totalHits} | ";'
done
echo
done