Maintenance scripts
[buildfarm-server.git] / cgi-bin / typedefs.pl
index c10a1cfaa0b7ade4ff65e2fbe4f1abdcc1955744..63c0fc56bf86d6cc9fd087da07375066c000bd2a 100755 (executable)
@@ -1,7 +1,18 @@
 #!/usr/bin/perl
 
+=comment
+
+Copyright (c) 2003-2010, Andrew Dunstan
+
+See accompanying License file for license details
+
+=cut 
+
 use strict;
 use DBI;
+use CGI;
+
+my $query = new CGI;
 
 use vars qw($dbhost $dbname $dbuser $dbpass $dbport);
 
@@ -25,6 +36,22 @@ my $sql = q{
 };
 my $builds = $dbh->selectall_arrayref($sql, { Slice => {} });
 
+
+if ($query->param('show_list'))
+{
+    print "Content-Type: text/html\n\n",
+    "<head><title>Typedefs URLs</title></head>\n",
+    "<body><h1>Typdefs URLs</h1>\n",
+    "<table border='1'><tr><th>member</th></tr>\n";
+
+    foreach my $build (@$builds)
+    {
+       print "<tr><td><a href='http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=$build->{sysname}\&amp;dt=$build->{snapshot}\&amp;stg=typedefs'>$build->{sysname}</a></td></tr>\n";
+    }
+    print "</table></body></html>\n";
+    exit;
+}
+
 $sql = q{
    select log_text
    from build_status_log