From 1be510f9529cb082f802408b472a77d074b394c0 Mon Sep 17 00:00:00 2001 From: Nicolas Vigier Date: Sun, 14 Apr 2013 13:46:12 +0000 Subject: Add zarb MLs html archives --- zarb-ml/mageia-sysadm/2011-January/002088.html | 136 +++++++++++++++++++++++++ 1 file changed, 136 insertions(+) create mode 100644 zarb-ml/mageia-sysadm/2011-January/002088.html (limited to 'zarb-ml/mageia-sysadm/2011-January/002088.html') diff --git a/zarb-ml/mageia-sysadm/2011-January/002088.html b/zarb-ml/mageia-sysadm/2011-January/002088.html new file mode 100644 index 000000000..7957861a5 --- /dev/null +++ b/zarb-ml/mageia-sysadm/2011-January/002088.html @@ -0,0 +1,136 @@ + + + + [Mageia-sysadm] [299] show users packages count + + + + + + + + + +

[Mageia-sysadm] [299] show users packages count

+ root at mageia.org + root at mageia.org +
+ Fri Jan 14 16:03:40 CET 2011 +

+
+ +
Revision: 299
+Author:   rda
+Date:     2011-01-14 16:03:40 +0100 (Fri, 14 Jan 2011)
+Log Message:
+-----------
+show users packages count
+
+Modified Paths:
+--------------
+    build_system/web/index.php
+
+Modified: build_system/web/index.php
+===================================================================
+--- build_system/web/index.php	2011-01-14 14:59:15 UTC (rev 298)
++++ build_system/web/index.php	2011-01-14 15:03:40 UTC (rev 299)
+@@ -230,6 +230,9 @@
+ );
+ $total = count($pkgs);
+ 
++// count users' packages
++$users = array();
++
+ // feedback labels
+ $badges = array(
+     'uploaded' => 'Congrats %s! \o/',
+@@ -245,6 +248,12 @@
+         $p['type'] = pkg_gettype($p);
+ 
+         $stats[$p['type']] += 1;
++
++        if (!array_key_exists($p['user'], $users))
++            $users[$p['user']] = 1;
++        else
++            $users[$p['user']] += 1;
++
+         $s .= sprintf($tmpl,
+             $p['type'],
+             key2date($key),
+@@ -289,7 +298,17 @@
+         $s .= sprintf('<tr class="%s"><td class="status-box"></td><td>%s</td><td>%d</td><td>%d%%</td></tr>',
+             $k, $k, $v, round($v/$total*100));
+     }
+-    $s .= '</table></div>';
++
++    $s .= '</table><br />';
++
++    $s .= '<table><caption>Packagers</caption><tr><th>User</th><th>Packages</th></tr>';
++    foreach ($users as $k => $v)
++        $s .= sprintf('<tr><td><a href="/?user=%s">%s</a></td><td>%d</td></tr>',
++            $k, $k, $v);
++
++    $s .= '</table>';
++    $s .= '</div>';
++
+     echo $s;
+ }
+ else
+-------------- next part --------------
+An HTML attachment was scrubbed...
+URL: </pipermail/mageia-sysadm/attachments/20110114/9879b7ba/attachment.html>
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+

+ +
+More information about the Mageia-sysadm +mailing list
+ -- cgit v1.2.1