【原创】解决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

blogdaren 2019-03-05 抢沙发 303人次

问题背景:

# composer require xxx/yyy

结果报错:

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

解决方案:

1、新建 composer.json

2、新增如下内容:

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

发表评论:

您的昵称:
电子邮件:
个人主页: