From 8a877d047b8ddfb3e802cfdb8f982f7e32c0f2cd Mon Sep 17 00:00:00 2001 From: Nicolas Vigier Date: Mon, 10 Dec 2012 17:07:56 +0000 Subject: Create themes/mageia/page_header.php --- themes/mageia/page_header.php | 76 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 themes/mageia/page_header.php (limited to 'themes/mageia/page_header.php') diff --git a/themes/mageia/page_header.php b/themes/mageia/page_header.php new file mode 100644 index 0000000..2f3ee7e --- /dev/null +++ b/themes/mageia/page_header.php @@ -0,0 +1,76 @@ + + + + + <?php echo strip_tags($title); ?> + + + + + + + + +/m", file_get_contents("http://check.mageia.org/cauldron/dependencies.rss"), $matches); + $unmaintained_count = file_exists(__DIR__ . '/data/unmaintained.txt') ? count(file(__DIR__ . '/data/unmaintained.txt')) : 0; + + if ($missing_deps_count > 0 + || $unmaintained_count > 0 + ) { + if ($missing_deps_count > 0) { + $figures_list[] = sprintf('%d broken deps.', + $missing_deps_count, + 'http://check.mageia.org/cauldron/dependencies.html' + ); + } + + if ($unmaintained_count > 0) { + $figures_list[] = sprintf('%d unmaintained', + $unmaintained_count, + 'data/unmaintained.txt' + ); + } + + if (count($figures_list) > 0) + $figures_list[count($figures_list)-1] .= sprintf(' %s', + 'https://wiki.mageia.org/en/Importing_packages', + 'YES you can help!', 'pick one'); + } + + preg_match_all('/(\d+)/', file_get_contents("https://bugs.mageia.org/buglist.cgi?quicksearch=%40qa-bugs+-kw%3Avali"), $matches); + $qa_bugs = $matches[1][0]; + if ($qa_bugs > 0) { + $figures_list[] = sprintf('%d update%s to validate + %s', + $qa_bugs, + 'http://mageia.madb.org/tools/updates', + plural($qa_bugs), + 'https://wiki.mageia.org/en/QA_process_for_validating_updates', + 'YES you can help!', 'see how' + ); + } + + $html_figures = null; + if (count($figures_list) > 0) { + $html_figures = 'Packages: ' . implode(', ', $figures_list) . '.'; + } + +?> +
+

+ +
+
+ -- cgit v1.2.1