parent
f6cae4ec4b
commit
e3964f5eb6
|
@ -1,6 +1,6 @@
|
||||||
#!/usr/bin/perl -w
|
#!/usr/bin/perl -w
|
||||||
use strict;
|
use strict;
|
||||||
my %h = {};
|
my %h;
|
||||||
while (<STDIN>) {
|
while (<STDIN>) {
|
||||||
chomp;
|
chomp;
|
||||||
my ($file, $line, $tilde) = split /:/;
|
my ($file, $line, $tilde) = split /:/;
|
||||||
|
@ -8,8 +8,8 @@ while (<STDIN>) {
|
||||||
$file =~ s/\/home\//\/~/;
|
$file =~ s/\/home\//\/~/;
|
||||||
$file =~ s/public_html\///;
|
$file =~ s/public_html\///;
|
||||||
$h{$tilde}{$file}++;
|
$h{$tilde}{$file}++;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
print qq{<html><head><title>Tilde.Club Connections</title>
|
print qq{<html><head><title>Tilde.Club Connections</title>
|
||||||
<link rel="stylesheet" type="text/css" href="css/social.css">
|
<link rel="stylesheet" type="text/css" href="css/social.css">
|
||||||
</head>
|
</head>
|
||||||
|
@ -19,14 +19,15 @@ print qq{<html><head><title>Tilde.Club Connections</title>
|
||||||
|
|
||||||
print "<table>";
|
print "<table>";
|
||||||
for my $x (sort keys %h) {
|
for my $x (sort keys %h) {
|
||||||
print "<tr><td class=\"user\"><a href=\"/$x\">$x</td><td class=\"linkedby\">is linked by</td><td class=\"linkers\">";
|
print "<tr><td class=\"user\"><a href=\"/$x\">$x</a></td><td class=\"linkedby\">is linked by</td><td class=\"linkers\">";
|
||||||
for my $y (sort keys %{$h{$x}}) {
|
for my $y (sort keys %{$h{$x}}) {
|
||||||
my $user = $y;
|
my $user = $y;
|
||||||
$user =~ m/(\~\w+)/;
|
if ($user =~ /~(\w+)/) {
|
||||||
print "<a name=\"$user\" href=\"$user\">$1</a> ";
|
my $username = "~$1"; # Add the tilde (~) before the username
|
||||||
|
print "<a href=\"/$username\">$username</a> ";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
print "</td></tr>\n"
|
print "</td></tr>\n";
|
||||||
};
|
}
|
||||||
print "</table>";
|
print "</table>";
|
||||||
print qq{</body></html>};
|
print qq{</body></html>};
|
||||||
|
|
Loading…
Reference in New Issue