各大云服务厂商逐渐公布了自己的 PHP Composer 全量镜像,整理以下『全量镜像』供大家选择。
PHP Composer 安装
1 2 3 4
| php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" php composer-setup.php php -r "unlink('composer-setup.php');" mv composer.phar /usr/local/bin/composer
|
自用稳定性很好,个人目前选择。
1
| composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/
|
1
| composer config -g repos.packagist composer https://mirrors.cloud.tencent.com/composer/
|
国内很早开放的免费镜像服务,其他服务商跟进之前的首选。
1
| composer config -g repo.packagist composer https://packagist.phpcomposer.com 1
| composer config -g repo.packagist composer https://mirrors.huaweicloud.com/repository/php/
|
1
| composer config -g repos.packagist composer https://php.cnpkg.org
|
关闭全局配置1
| composer config -g --unset repos.packagist
|
多线程下载1 2
| composer global require hirak/prestissimo composer clearcache |
|
No comments:
Post a Comment