diff options
Diffstat (limited to 'all.php')
-rw-r--r-- | all.php | 26 |
1 files changed, 21 insertions, 5 deletions
@@ -127,7 +127,21 @@ function report ($db) ? $rpms["devel-"]->ver : ""); - switch ($repo['sub']) { + if (strpos($repo['sub'], '-os') + || strpos($repo['sub'], '-base') + || strpos($repo['sub'], '-optional') + || strpos($repo['sub'], '-stable') + ) { + // For CentOS + $repotype = 'base'; + } else if (strpos($repo['sub'], 'testing')) { + $repotype = 'testing'; + } else if (strpos($repo['sub'], 'updates')) { + $repotype = 'updates'; + } else { + $repotype = $repo['sub']; + } + switch ($repotype) { case "base": if (isset($rpms[$repo['main']."-updates"])) { $display .= sprintf( @@ -155,17 +169,19 @@ function report ($db) break; case "updates": $display .= sprintf( - "<strong>%s</strong>-%s <small>(updates)</small><br/>", + "<strong>%s</strong>-%s <small>(%s)</small><br/>", $rpm->ver, - $rpm->rel + $rpm->rel, + $repo['sub'] ); $class = ($rpm->ver == $maxver ? "check" : "attn"); break; case "testing": $display .= sprintf( - "%s-%s <small>(testing)</small><br/>", + "%s-%s <small>(%s)</small><br/>", $rpm->ver, - $rpm->rel + $rpm->rel, + $repo['sub'] ); $class = ($rpm->ver == $maxver ? "info" : "attn"); break; |