Re: [PROPOSAL]How To Download all the packages in one
| From: | David Grant | Date: | Sat, 25 Oct 2003 06:38:05 +0000 |
| Subject: | Re: [PROPOSAL]How To Download all the packages in one | ||
| References: | 1 2 3 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-22983@lists.php.net to get a copy of this message | ||
On Sat, 2003-10-25 at 07:35, Greg Beaver wrote:
> It would be a very good idea to add an option to download-all to
> download releases better than preferred_state.
>
> pear download-all --use-preferred-state
> pear download-all -u
>
> I can add this for PHP 4.3.4 release, if there is interest.
>
> It would involve adding in a require_once 'PEAR/Common.php'; at the top
> of PEAR/Command/Mirror.php, and one thing to the foreach loop:
>
> if (isset($options['use-preferred-state']) &&
> in_array($pkg['state'], PEAR_Common::betterStates($preferred_state)) {
> continue;
> }
>
> outside the foreach() loop, we would have:
>
> $preferred_state = $this->config->get('preferred_state');
> if (!in_array($preferred_state, PEAR_Common::getReleaseStates()) {
> $preferred_state = 'stable';
> }
It might also be a useful filter for the package search mechanism on
pear.php.net.
Regards,
David