2002-08-16 08:42:43 +00:00
|
|
|
#!/usr/bin/perl
|
|
|
|
|
|
|
|
while(<STDIN>) {
|
|
|
|
|
|
|
|
$_ =~ s/\</</g;
|
|
|
|
$_ =~ s/\>/>/g;
|
|
|
|
|
2002-08-16 09:02:48 +00:00
|
|
|
$_ =~ s/(http:\/\/([a-zA-Z0-9_.\/-]*)[^).])/\<a href=\"$1\"\>$1\<\/a\>/g;
|
|
|
|
|
|
|
|
$_ =~ s/^$/\ /g; # empty lines are nbsp
|
|
|
|
$_ =~ s/(\\|\/)$/$1 /g; # clobber backslash on end of line
|
|
|
|
|
2002-08-16 08:42:43 +00:00
|
|
|
|
|
|
|
print $_;
|
|
|
|
}
|