]> granicus.if.org Git - php/commitdiff
add modes to list-all. fix a mergerbug
authorChristian Dickmann <dickmann@php.net>
Sat, 8 Jun 2002 18:44:34 +0000 (18:44 +0000)
committerChristian Dickmann <dickmann@php.net>
Sat, 8 Jun 2002 18:44:34 +0000 (18:44 +0000)
pear/PEAR/Command/Config.php
pear/PEAR/Command/Remote.php

index 2639ad77f7a277f320897d161add2c4d9bc3c1dc..b8f14511dd723ef594e6ea60afea270d2899ec64 100644 (file)
@@ -147,9 +147,6 @@ displays help for all configuration parameters.
             $failmsg .= $error;
             return PEAR::raiseError($failmsg);
         }
-        if ($params[0] == 'umask') {
-            list($params[1]) = sscanf($params[1], '%o');
-        }
         if (!call_user_func_array(array(&$this->config, 'set'), $params))
         {
             $failmsg = "config-set (" . implode(", ", $params) . ") failed";
index 9cb8106e54f95b8c7a48e7a57a743c3f6366fbee..3ae167a25534b6ce82ac72962348c3a9ac26ca19 100644 (file)
@@ -125,6 +125,8 @@ version of DB is 1.2, the downloaded file will be DB-1.2.tgz.',
         $info['installed'] = $installed['version'] ? $installed['version'] : '- no -';
 
         $this->ui->outputData($info, $command);
+        
+        return true;
     }
 
     // }}}
@@ -176,6 +178,19 @@ version of DB is 1.2, the downloaded file will be DB-1.2.tgz.',
             if (isset($params[$name]))
                 $desc .= "\n\n".$info['description'];
 
+            if (isset($options['mode']))
+            {
+                if ($options['mode'] == 'installed' && !isset($installed['version']))
+                    continue;
+                if ($options['mode'] == 'notinstalled' && isset($installed['version']))
+                    continue;
+                if ($options['mode'] == 'upgrades' 
+                    && (!isset($installed['version']) || $installed['version'] == $info['stable']))
+                {
+                    continue;
+                };
+            };
+
             $data['data'][$info['category']][] = array(
                 $name,
                 $info['stable'],