php composer 配置

2022/3/30 20:19:33

本文主要是介绍php composer 配置,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

composer 配置

阿里云 Composer 全量镜像

https://developer.aliyun.com/composer
https://www.cnblogs.com/abcdefghi123/p/15670845.html

换http源,更改配置不要使用https加密连接

composer config -g repo.packagist composer http://packagist.phpcomposer.com
composer config -g secure-http false

composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/
composer config -g -l

诊断

composer diagnose

compose 安装

curl -sS https://getcomposer.org/installer | php  # 安装
mv composer.phar /usr/local/bin/composer  #将composer.phar文件移动到bin目录以便全局使用composer命令
composer config -g repo.packagist composer https://packagist.phpcomposer.com  #切换国内源

composer  # 验证

# 常用操作
/usr/bin/composer update
/usr/bin/composer install
php -d memory_limit=-1 /usr/bin/composer install

镜像源

https://tool.lu/pkg/
https://learnku.com/articles/15977/composer-accelerate-and-modify-mirror-source-in-china



这篇关于php composer 配置的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!


扫一扫关注最新编程教程