On Sat, 2010-07-03 at 11:07 +0200, Jozsi Avadkan wrote:
> input:
> http://pastebin.com/raw.php?i=MqPXZwc3
> 
> output:
> http://pastebin.com/raw.php?i=8QCkp4yv

Just for fun:
perl -ne 'm{^(([^/]*).*/([^/]*).html)}; exit unless defined($2); if ($d ne 
$2){defined($d) && print "<br>\n"; $d = $2; print "<br><font 
size=4>$d</font><br>\n";} print qq{<a href="$1">$3</a> | \n};' < input > output

Some tweaks required depending on whether you do or don't want trailing
|'s and/or trailing spaces, and I agree there are 2 entries in your
sample output that don't match :-)

Richard



-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: 
http://lists.debian.org/1278411378.30144.7.ca...@diamond.lan.walnut.gen.nz

Reply via email to