From: Martin Jansen Date: Thu, 5 Jun 2003 06:32:10 +0000 (+0000) Subject: * Add support for X-Git-Tag: RELEASE_1_0_2~422 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5f262f10abfa7ac8958e9bf140778809f4f381ec;p=php * Add support for # Bug: #23933 --- diff --git a/pear/PEAR/Command/Registry.php b/pear/PEAR/Command/Registry.php index 20860cf4a2..01029df1ac 100644 --- a/pear/PEAR/Command/Registry.php +++ b/pear/PEAR/Command/Registry.php @@ -284,6 +284,36 @@ installed package.' $info[$key] = $dstr; break; } + case 'provides' : { + $debug = $this->config->get('verbose'); + if ($debug < 2) { + $pstr = 'Classes: '; + } else { + $pstr = ''; + } + foreach ($info[$key] as $p) { + if ($debug < 2 && $p['type'] != "class") { + continue; + } + // Only print classes when verbosity mode is < 2 + if ($debug < 2) { + if ($i++ > 0) { + $pstr .= ", "; + } + $pstr .= $p['name']; + } else { + if ($i++ > 0) { + $pstr .= "\n"; + } + $pstr .= ucfirst($p['type']) . " " . $p['name']; + if (isset($p['explicit']) && $p['explicit'] == 1) { + $pstr .= " (explicit)"; + } + } + } + $info[$key] = $pstr; + break; + } default: { $info[$key] = implode(", ", $info[$key]); break;