解决composer install/required遇到:Your requirements could not be resolved to an installable set of pa...

解决composer install遇到:Your requirements could not be resolved to an installable set of packages

  • 网上很多文章都是说忽略版本什么的,但是一直没效果,后来索性create一个项目,结果还是失败,考虑可能是源的问题,因为装好composer,很多网络文章建议替换源,有的源可能已经失效了,所以造成这种问题,解决方式:
    composer config -g repo.packagist composer https://packagist.org
    切换为官方源
    或者
    composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/

具体参考
https://learnku.com/articles/15977/composer-accelerate-and-modify-mirror-source-in-china

你可能感兴趣的:(解决composer install/required遇到:Your requirements could not be resolved to an installable set of pa...)