百分百源码网-让建站变得如此简单! 登录 注册 签到领金币!

主页 | 如何升级VIP | TAG标签

当前位置: 主页>网站教程>网页制作> 处置 PHP 开发版本题目
分享文章到:

处置 PHP 开发版本题目

发布时间:12/01 来源:未知 浏览: 关键词:
在安置一个开源项目时,作者当地用了 PHP 7.1 停止开发,而我当地是 PHP 7.0, 于是悲剧发生了,显现了这样的错误:requires php ^7.1 -> your PHP version (7.0.13) does not satisfy that requirement..

一、Composer 安置包

composer install 之后报错

vagrant@homestead:~/Code/sample$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Installation request for doctrine/instantiator 1.1.0 -> satisfiable by doctrine/instantiator[1.1.0].
    - doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.13) does not satisfy that requirement.
  Problem 2
    - doctrine/instantiator 1.1.0 requires php ^7.1 -> your PHP version (7.0.13) does not satisfy that requirement.
    - phpunit/phpunit-mock-objects 2.3.8 requires doctrine/instantiator ^1.0.2 -> satisfiable by doctrine/instantiator[1.1.0].
    - Installation request for phpunit/phpunit-mock-objects 2.3.8 -> satisfiable by phpunit/phpunit-mock-objects[2.3.8].

二、解决办法

删除 composer.lock 文件,从新施行 composer install,这样就能从新生成 composer.lock 文件了。

composer 包主动加载后,会生成一个 composer.lock 锁文件,所以,在从GitHub拉取别人的代码后,需要对这个文件停止删除。

引荐:《PHP视频教程》

以上就是处置 PHP 开发版本问题的具体内容,更多请关注百分百源码网其它相关文章!

打赏

打赏

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码打赏,你说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦

百分百源码网 建议打赏1~10元,土豪随意,感谢您的阅读!

共有154人阅读,期待你的评论!发表评论
昵称: 网址: 验证码: 点击我更换图片
最新评论

本文标签

广告赞助

能出一分力是一分吧!

订阅获得更多模板

本文标签

广告赞助

订阅获得更多模板