diff options
-rw-r--r-- | buildmaster/blacklist.php | 3 | ||||
-rw-r--r-- | buildmaster/build-list-links.php | 4 | ||||
-rw-r--r-- | buildmaster/build-list.php | 5 | ||||
-rw-r--r-- | buildmaster/build-slaves.php | 4 | ||||
-rw-r--r-- | buildmaster/deletion-links.php | 4 | ||||
-rw-r--r-- | buildmaster/dependencies.php | 4 | ||||
-rw-r--r-- | buildmaster/gpg-keys.php | 2 | ||||
-rw-r--r-- | buildmaster/index.php | 4 | ||||
-rw-r--r-- | buildmaster/log.php | 3 | ||||
-rw-r--r-- | buildmaster/mysql-issues.php | 4 | ||||
-rw-r--r-- | buildmaster/statistics.php | 4 | ||||
-rw-r--r-- | buildmaster/status.php | 6 | ||||
-rw-r--r-- | buildmaster/to-delete.php | 4 | ||||
-rw-r--r-- | buildmaster/todos.php | 4 | ||||
-rw-r--r-- | init.php | 2 | ||||
-rw-r--r-- | lib/style.php | 2 | ||||
-rw-r--r-- | mirrors/index.php | 5 | ||||
-rw-r--r-- | mirrors/status.php | 3 | ||||
-rw-r--r-- | packages/index.php | 6 | ||||
-rw-r--r-- | packages/pkginfo.php | 5 |
20 files changed, 45 insertions, 33 deletions
diff --git a/buildmaster/blacklist.php b/buildmaster/blacklist.php index fc49d42..ab9f89f 100644 --- a/buildmaster/blacklist.php +++ b/buildmaster/blacklist.php @@ -1,6 +1,7 @@ <?php +require "../init.php" - include "lib/mysql.php"; +require BASE . "/lib/mysql.php"; $result = mysql_run_query( "SELECT DISTINCT `architectures`.`name` AS `architecture`,`package_sources`.`pkgbase`,`build_assignments`.`is_black_listed` " . diff --git a/buildmaster/build-list-links.php b/buildmaster/build-list-links.php index 7b0243e..cbd41ef 100644 --- a/buildmaster/build-list-links.php +++ b/buildmaster/build-list-links.php @@ -1,6 +1,6 @@ <?php - -include "lib/mysql.php"; +require "../init.php"; +require BASE . "/lib/mysql.php"; $edges = ""; $knots = ""; diff --git a/buildmaster/build-list.php b/buildmaster/build-list.php index 31d0dd6..e3f7339 100644 --- a/buildmaster/build-list.php +++ b/buildmaster/build-list.php @@ -1,7 +1,8 @@ <?php +require "../init.php"; -include "lib/mysql.php"; -include "lib/style.php"; +require BASE . "/lib/mysql.php"; +require BASE . "/lib/style.php"; if (isset($_GET["show"])) $to_show=$_GET["show"]; diff --git a/buildmaster/build-slaves.php b/buildmaster/build-slaves.php index 651d661..e488f3c 100644 --- a/buildmaster/build-slaves.php +++ b/buildmaster/build-slaves.php @@ -1,6 +1,6 @@ <?php - - include "lib/mysql.php"; +require "../init.php"; +require BASE . "/lib/mysql.php"; $result = mysql_run_query( "SELECT" . diff --git a/buildmaster/deletion-links.php b/buildmaster/deletion-links.php index 39df340..32fa1b9 100644 --- a/buildmaster/deletion-links.php +++ b/buildmaster/deletion-links.php @@ -1,6 +1,6 @@ <?php - -include "lib/mysql.php"; +require "../init.php"; +require BASE . "/lib/mysql.php"; $edges = ""; $knots = ""; diff --git a/buildmaster/dependencies.php b/buildmaster/dependencies.php index dddb662..7826b55 100644 --- a/buildmaster/dependencies.php +++ b/buildmaster/dependencies.php @@ -1,6 +1,6 @@ <?php - -include "lib/mysql.php"; +require "../init.php"; +require BASE . "/lib/mysql.php"; $match = ""; diff --git a/buildmaster/gpg-keys.php b/buildmaster/gpg-keys.php index b506b0c..9a43a87 100644 --- a/buildmaster/gpg-keys.php +++ b/buildmaster/gpg-keys.php @@ -1,4 +1,6 @@ <?php +require "../init.php" +require BASE . "/lib/mysql.php"; include "lib/mysql.php"; diff --git a/buildmaster/index.php b/buildmaster/index.php index a14a0ed..0bd1e55 100644 --- a/buildmaster/index.php +++ b/buildmaster/index.php @@ -1,6 +1,6 @@ <?php - - include "lib/mysql.php"; +require "../init.php"; +require BASE . "/lib/mysql.php"; ?> <html> diff --git a/buildmaster/log.php b/buildmaster/log.php index 55ce955..139f94c 100644 --- a/buildmaster/log.php +++ b/buildmaster/log.php @@ -1,6 +1,7 @@ <?php +require "../init.php" +require BASE . "/lib/mysql.php"; - include "lib/mysql.php"; $filter = ""; if (isset($_GET["show"]) && diff --git a/buildmaster/mysql-issues.php b/buildmaster/mysql-issues.php index 6547a34..02eb912 100644 --- a/buildmaster/mysql-issues.php +++ b/buildmaster/mysql-issues.php @@ -1,6 +1,6 @@ <?php - - include "lib/mysql.php"; +require "../init.php" +include BASE . "/lib/mysql.php"; if (isset($_GET["ignore-haskell"])) $ignore = " AND `install_targets`.`name` NOT LIKE \"libHS%\""; diff --git a/buildmaster/statistics.php b/buildmaster/statistics.php index 8c13548..56b4984 100644 --- a/buildmaster/statistics.php +++ b/buildmaster/statistics.php @@ -1,6 +1,6 @@ <?php - -include "lib/mysql.php"; +require "../init.php"; +require BASE . "/lib/mysql.php"; if (isset($_GET["from"])) $min_time="from_base64(\"" . base64_encode("-".$_GET["from"]) . "\")"; diff --git a/buildmaster/status.php b/buildmaster/status.php index 2b1bd11..e129963 100644 --- a/buildmaster/status.php +++ b/buildmaster/status.php @@ -1,7 +1,7 @@ <?php - -include "lib/mysql.php"; -include "lib/style.php"; +require "../init.php"; +include BASE . "/lib/mysql.php"; +include BASE . "/lib/style.php"; $result = mysql_run_query( "SELECT MAX(`package_sources`.`commit_time`) AS `last_commit`" . diff --git a/buildmaster/to-delete.php b/buildmaster/to-delete.php index da9ded9..8a7b7ef 100644 --- a/buildmaster/to-delete.php +++ b/buildmaster/to-delete.php @@ -1,6 +1,6 @@ <?php - - include "lib/mysql.php"; +require "../init.php"; +require BASE . "/lib/mysql.php"; $result = mysql_run_query( "SELECT " . diff --git a/buildmaster/todos.php b/buildmaster/todos.php index 3251778..fa61a3f 100644 --- a/buildmaster/todos.php +++ b/buildmaster/todos.php @@ -1,6 +1,6 @@ <?php - -include "lib/mysql.php"; +require "../init.php"; +include BASE . "/lib/mysql.php"; $result = mysql_run_query( "SELECT DISTINCT " . diff --git a/init.php b/init.php new file mode 100644 index 0000000..6c8a8f4 --- /dev/null +++ b/init.php @@ -0,0 +1,2 @@ +<?php +define("BASE", __DIR__); diff --git a/lib/style.php b/lib/style.php index 6911bdd..4b6439b 100644 --- a/lib/style.php +++ b/lib/style.php @@ -3,7 +3,7 @@ if (function_exists("print_header")) return; -include "lib/mysql.php"; +require "lib/mysql.php"; function print_header($title) { ?> diff --git a/mirrors/index.php b/mirrors/index.php index 85ec4e0..114e03c 100644 --- a/mirrors/index.php +++ b/mirrors/index.php @@ -1,7 +1,8 @@ <?php +require "../init.php"; -include "lib/mysql.php"; -include "lib/style.php"; +require BASE . "/lib/mysql.php"; +require BASE . "/lib/style.php"; $cutoff = 3600; diff --git a/mirrors/status.php b/mirrors/status.php index 1e1f274..9989d75 100644 --- a/mirrors/status.php +++ b/mirrors/status.php @@ -1,6 +1,7 @@ <?php +require "../init.php"; -include "lib/mysql.php"; +require BASE . "/lib/mysql.php"; $cutoff = 86400; diff --git a/packages/index.php b/packages/index.php index cd1413d..bb59503 100644 --- a/packages/index.php +++ b/packages/index.php @@ -1,7 +1,9 @@ <?php +require "../init.php"; + +require BASE . "/lib/mysql.php"; +require BASE . "/lib/style.php"; - include "lib/mysql.php"; - include "lib/style.php"; foreach (array("bugs","sort","del") as $expected_param) if (! isset($_GET[$expected_param])) diff --git a/packages/pkginfo.php b/packages/pkginfo.php index fe1066b..e76bcec 100644 --- a/packages/pkginfo.php +++ b/packages/pkginfo.php @@ -1,7 +1,8 @@ <?php +require "../init.php" - include "lib/mysql.php"; - include "lib/style.php"; +require BASE . "/lib/mysql.php"; +require BASE . "/lib/style.php"; $json_content = json_decode( file_get_contents( |