summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlvaro Herrera2009-05-27 19:48:37 +0000
committerAlvaro Herrera2009-05-27 19:48:37 +0000
commite85e328989407273e0169113f5416e5562340beb (patch)
tree77e347e0e2c115ea02c74aa51b7634c411e699e1
parent2d24eff77bef3034965582781965ad4a2f767fea (diff)
Add the text/plain link on each message page
git-svn-id: file:///Users/dpage/pgweb/svn-repo/trunk@2498 8f5c7a92-453e-0410-a47f-ad33c8a6b003
-rwxr-xr-xarchives/bin/msgid2link.pl9
1 files changed, 5 insertions, 4 deletions
diff --git a/archives/bin/msgid2link.pl b/archives/bin/msgid2link.pl
index 3e39104f..efe96fb6 100755
--- a/archives/bin/msgid2link.pl
+++ b/archives/bin/msgid2link.pl
@@ -31,24 +31,25 @@ while (my $in_filename = glob("msg*.php"))
{
# prevent running on a file we already processed, by
# adding our marker at the top of the file
- last if (m/^<!-- msgid2link -->/);
+ last if (m/^<!-- msgid2linkv2 -->/);
if (m/^<!-- MHonArc/)
{
- print $OUT "<!-- msgid2link -->\n";
+ print $OUT "<!-- msgid2linkv2 -->\n";
}
if (!$changes && m/>Message-id(<.*>)?:/ && !m/<a href=/)
{
s/\(dot\)/./g;
s/\(at\)/@/g;
- m/^(.*&lt;)(.*)(&gt;<\/li>)$/;
+ m/^(.*&lt;)(.*)(&gt;)(<\/li>)$/;
my $lead = $1;
my $link = $2;
my $ulink = $2;
my $trailer = $3;
+ my $eol = $4;
# do we need more HTML de-escaping?
$link =~ s/&amp;/&/g;
- print $OUT qq{$lead<a href="http://archives.postgresql.org/message-id/$link">$ulink</a>$trailer};
+ print $OUT qq{$lead<a href="http://archives.postgresql.org/message-id/$link">$ulink</a>$trailer &lt;<a href="http://archives.postgresql.org/msgtxt.php?id=$link">text/plain</a>>$eol};
$changes = 1;
}
else