各种方法都尝试过了,然而最大的可能就是不能访问国外的资源!
1.使用vpnFQ下载
2.修改一下composer的配置,命令如下:
composer config -g repo.packagist composer https://packagist.phpcomposer.com
创建laravel项目:
composer create-project laravel/framework=5.5.45 project_name
composer安装:
wget https://getcomposer.org/composer.phar
mv composer.phar composer
chmod +x composer
mv composer /usr/local/bin
更换阿里包源:
> composer config -g repo.packagist composer https://mirrors.aliyun.com/composer
> composer clear-cache
> composer config -gl #查看当前包源信息