]> git.pld-linux.org Git - projects/buildlogs.git/commitdiff
- fix html typo; add links to rpm changelogs
authorElan Ruusamäe <glen@pld-linux.org>
Mon, 20 Oct 2014 12:59:06 +0000 (12:59 +0000)
committerElan Ruusamäe <glen@pld-linux.org>
Mon, 20 Oct 2014 12:59:06 +0000 (12:59 +0000)
index.php

index a3bc66284b84432072c0d8a622ecc823248d6572..f3501e4914ba30864ad2a3394de9abb87f92f462 100644 (file)
--- a/index.php
+++ b/index.php
@@ -110,6 +110,9 @@ TH { font-family: arial,helvetica,sans-serif;
        color: #111;
        background-color: #161;
 }
+.changelog a {
+       color: #fff;
+}
 //-->
 </style>
  </head>
@@ -293,7 +296,7 @@ function dump_log($tail)
 
        echo "<h1>$df</h1>";
 
-       echo "<table border=\"0\" cellpadding=\"3\" cellspacing=\"1\" bgcolor=\"#000000\" width="\100%\">";
+       echo "<table border=\"0\" cellpadding=\"3\" cellspacing=\"1\" bgcolor=\"#000000\" width=\"100%\">";
 
        function one_item($h, $t) {
                echo "<tr><td bgcolor=\"#ccccff\">$h:</td>".
@@ -382,6 +385,15 @@ function dump_log($tail)
                        $toc_elem = "make {$m['target']}";
                        $err_elem = $s;
                        $s = "<span class=line id=make-{$m['target']}>$s</span>";
+               } elseif (preg_match('/^(?P<line>- For complete changelog see:) (?P<link>.+)$/', $s, $m)) {
+                       // rpm changelog link
+                       $link = "<a href=\"{$m['link']}\">{$m['link']}</a>";
+                       $s = "<span class=changelog>{$m['line']} $link<br/></span>";
+               } elseif (preg_match('/^(?P<line>\* \w{3} \w{3} [ \d]{2} \d{4} .*?) (?P<hash>[a-z0-9]{7})$/', $s, $m)) {
+                       // rpm changelogs
+                       $url = "http://git.pld-linux.org/?p=packages/{$name_url}.git;a=commitdiff;h={$m['hash']}";
+                       $link = "<a href=\"$url\">{$m['hash']}</a>";
+                       $s = "<span class=changelog>{$m['line']} $link<br/></span>";
                } elseif (substr($s, 0, 2) == "+ ") {
                        // shell verbose
                        $s = "<span class=verbose>$s</span>";
@@ -530,7 +542,7 @@ function list_archs()
             "alt=\""._("Powered by PLD Linux")."\" border=\"0\" /></a><br />\n" .
             "<small>(c) 2002-". date("Y") . " ". 
             "<a href=\"mailto:feedback@pld-linux.org\">PLD&nbsp;Team</a><br />\n".
-            '$Revision: 1.35 $'.
+            '$Revision: 1.36 $'.
             "</small></div>\n";
 
        # smile ;)
@@ -904,7 +916,7 @@ function welcome()
 <!-- ech... niech strace... -->
 <a href="mailto:feedback@pld-linux.org"><?=_("to us")?></a>. <?=_("Positive opinions are also")?>
 <a href="mailto:feedback@pld-linux.org"><?=_("welcome")?></a> ;)</p>
-<p>Version: $Id: index.php,v 1.35 2014/10/18 10:25:20 arekm Exp $</p>
+<p>Version: $Id: index.php,v 1.36 2014/10/18 10:30:03 arekm Exp $</p>
 </td><td width="20%">&nbsp;</td></tr>
 </table>
 <?php
This page took 0.104041 seconds and 4 git commands to generate.