1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
|
#!/usr/bin/perl -w
use English;
#
# Reads the doc/programs/html/index.html file
#
# writes the Appdocs page
$text = "";
while (<>) {
$text .= $_;
}
print "{|\n";
print "|-\n";
print "!Program name\n";
print "!Description\n";
while($text =~ /<[Tt][Dd][^>]*>.*?<\/[Tt][Dd]>/gosm){
$r = $MATCH;
if($r =~ />([^<]+)<\/a>/) {
$name = $1;
$cname = ucfirst($name);
print "|-\n";
print "|[[Appdoc:$cname|$name]]\n";
print "|\{\{:Appinc:Short$cname}}\n";
}
}
print "|}\n";
|