diff options
-rwxr-xr-x | check.php | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -193,9 +193,19 @@ if (!$cli) { $pids = array(); $ref = getRepoTime($full); if ($ref) { - printf(($cli ? "Check %d mirrors of %s (%s)\n" : "<h3>%s - %s</h3>\n"), count($mirrors), $name, date('r', $ref)); if (!$cli) echo "<ul class='pkglist'>\n"; - foreach ($mirrors as $mirror) { + if (isset($_SERVER['argv'][1])) { + $tocheck = []; + foreach ($mirrors as $mirror) { + if (preg_match('|'.$_SERVER['argv'][1].'|', $mirror)) { + $tocheck[] = $mirror; + } + } + } else { + $tocheck = $mirrors; + } + printf(($cli ? "Check %d mirror(s) of %s (%s)\n" : "<h3>%s - %s</h3>\n"), count($tocheck), $name, date('r', $ref)); + foreach ($tocheck as $mirror) { if ($_SERVER['argc']>1 && !strpos($mirror, $_SERVER['argv'][1])) { continue; } |