Rosetta Code/List authors of task descriptions: Difference between revisions
Rosetta Code/List authors of task descriptions (view source)
Revision as of 00:42, 11 October 2017
, 6 years ago→{{header|Perl 6}}: work around wonky syntax highlighting
Thundergnat (talk | contribs) m (Oops, months should not be zero indexed) |
Thundergnat (talk | contribs) m (→{{header|Perl 6}}: work around wonky syntax highlighting) |
||
Line 290:
my $html = $ua.get($page).content;
my $xmldoc = parse-html($html, :TAG<div>, :id<mw-pages>);
my @tasks = parse-html($xmldoc[0].Str, :TAG<li>).Str.comb( /'/wiki/' <-["]>+ / )».substr(6); #'"
my $f = open("./RC_{$category}.txt", :w) or die "$!\n";
note "Writing $category file...";
Line 347:
# Parse out human readable title
$line ~~ m| '<a href="/mw/index.php?title=' $title '&' .+? 'title="'(<-["]>+)'"' |; #"'
%tasks{$title}{'title'} = $0.Str;
|