summaryrefslogtreecommitdiff
path: root/buildmaster/blacklist.php
blob: 24247e85201f09d6f512b2481c91ec62f872ff52 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<?php
require_once "../init.php";

require_once BASE . "/lib/mysql.php";

  $result = mysql_run_query(
    "SELECT DISTINCT" .
    " GROUP_CONCAT(`architectures`.`name`) AS `architectures`," .
    "`package_sources`.`pkgbase`," .
    "`build_assignments`.`is_black_listed` " .
    "FROM `build_assignments` " .
    mysql_join_build_assignments_architectures() .
    mysql_join_build_assignments_package_sources() .
    "WHERE `build_assignments`.`is_black_listed` IS NOT NULL " .
    "GROUP BY CONCAT(to_base64(`package_sources`.`pkgbase`),\" - \",to_base64(`build_assignments`.`is_black_listed`)) " .
    "ORDER BY `package_sources`.`pkgbase`"
  );

?>
<html>
  <head>
    <title>Blacklisted packages</title>
    <link rel="stylesheet" type="text/css" href="/static/style.css">
  </head>
  <body>
<?php show_warning_on_offline_slave(); ?>
    <table>
      <tr>
        <th>architectures</th>
        <th>package</th>
        <th>reason</th>
      </tr>
<?php

if ($result -> num_rows > 0) {
  while($row = $result->fetch_assoc()) {
    print "      <tr>\n";
    print "        <td>";
    print $row["architectures"];
    print "</td>\n";
    print "        <td>";
    print $row["pkgbase"];
    print "</td>\n";
    print "        <td>";
    print preg_replace(
      array (
        "/FS32#(\\d+)/",
        "/FS#(\\d+)/"
      ),
      array (
        "<a href=\"https://bugs.archlinux32.org/index.php?do=details&task_id=$1\">$0</a>",
        "<a href=\"https://bugs.archlinux.org/task/$1\">$0</a>"
      ),
      $row["is_black_listed"]
    );
    print "</td>\n";
    print "      </tr>\n";
  }
}
?>
    </table>
  </body>
</html>