解决composer报错:Could not find a version of package xxx/yyy matching your minimum-stability (stable). Require it with an explicit version constraint allowing its desired stability

参考:http://www.blogdaren.com/post-2536.html

问题背景:

  1. # composer require xxx/yyy

结果报错:

  1. [InvalidArgumentException]
  2. Could not find a version of package xxx/yyy matching your minimum-stability (stable).Require it with an explicit version constrai
  3. nt allowing its desired stability.

解决方案:

1、新建 composer.json

2、新增如下内容:

  1. {
  2. "require":{
  3. "xxx/yyy":"dev-master"
  4. }
  5. }
3、执行命令:
  1. # composer install

 

posted @ 2020-03-01 16:32  狂客  阅读(5267)  评论(0编辑  收藏  举报