将 laravel 4 包升级到 laravel 5 的依赖性问题
Dependency issue upgrading laravel 4 package to laravel 5
我正在尝试为 Laravel 5 更新作曲家包。 Laravel 4 composer.json 架构包括:
"require": {
"php": ">=5.3.3",
"illuminate/foundation": "4.*",
"illuminate/support": "4.*"
},
我正在尝试将其更新为如下内容:
"require": {
"php": ">=5.3.3",
"illuminate/foundation": "4.*",
"illuminate/support": "5.*"
},
在运行composer install
之后,我得到一个错误说找不到illuminate/foundation
,所以我尝试把minimum-stability
改成dev
。 Composer 现在可以找到包,但出现此错误:
Problem 1
- illuminate/exception dev-master requires illuminate/support 5.0.* -> satisfiable by illuminate/support[5.0.x-dev, v5.0.0, v5.0.4].
- Can only install one of: illuminate/support[dev-master, 5.0.x-dev].
- Can only install one of: illuminate/support[v5.0.0, dev-master].
- Can only install one of: illuminate/support[v5.0.4, dev-master].
- illuminate/foundation 4.0.x-dev requires illuminate/exception dev-master -> satisfiable by illuminate/exception[dev-master].
- illuminate/foundation 4.0.x-dev requires illuminate/support dev-master -> satisfiable by illuminate/support[dev-master].
- Installation request for illuminate/foundation 4.* -> satisfiable by illuminate/foundation[4.0.x-dev].
我需要 illuminate/support
达到 5+,因为 Laravel 5 的服务提供商在配置发布方面发生了变化。我需要 illuminate/foundation
因为单元测试需要它。
我如何构造这些依赖项以便 composer 可以安装它们?
我也试过将 illuminate/support
设置为 dev-master
,并且都将包照亮为 dev-master
,都解决了不同的错误。解决此问题的唯一方法是更新上游依赖项吗?
我已经获得要安装的更新并且(看起来)在 Laravel 5 安装中正常工作。我可能只是通过使整个 laravel/framework
成为依赖项来解决我的问题,但我真的不认为我想将其作为解决方案。
运行 composer 安装的额外输出
illuminate/support
@ dev-master
和 illuminate/foundation
在 4.*
:
Problem 1
- Installation request for illuminate/foundation 4.* -> satisfiable by illuminate/foundation[4.0.x-dev].
- illuminate/exception dev-master requires illuminate/support 5.0.* -> satisfiable by illuminate/support[5.0.x-dev].
- Can only install one of: illuminate/support[dev-master, 5.0.x-dev].
- illuminate/foundation 4.0.x-dev requires illuminate/exception dev-master -> satisfiable by illuminate/exception[dev-master].
- Installation request for illuminate/support dev-master -> satisfiable by illuminate/support[dev-master].
illuminate/support
@ dev-master
和 illuminate/foundation
在 dev-master
:
Problem 1
- Installation request for illuminate/foundation dev-master -> satisfiable by illuminate/foundation[dev-master].
- illuminate/exception dev-master requires illuminate/support 5.0.* -> satisfiable by illuminate/support[5.0.x-dev].
- Can only install one of: illuminate/support[dev-master, 5.0.x-dev].
- illuminate/foundation dev-master requires illuminate/exception dev-master -> satisfiable by illuminate/exception[dev-master].
- Installation request for illuminate/support dev-master -> satisfiable by illuminate/support[dev-master].
永远不要使用 dev-master
作为版本,只需使用 5.*
(对于两个包)就可以了。
我正在尝试为 Laravel 5 更新作曲家包。 Laravel 4 composer.json 架构包括:
"require": {
"php": ">=5.3.3",
"illuminate/foundation": "4.*",
"illuminate/support": "4.*"
},
我正在尝试将其更新为如下内容:
"require": {
"php": ">=5.3.3",
"illuminate/foundation": "4.*",
"illuminate/support": "5.*"
},
在运行composer install
之后,我得到一个错误说找不到illuminate/foundation
,所以我尝试把minimum-stability
改成dev
。 Composer 现在可以找到包,但出现此错误:
Problem 1
- illuminate/exception dev-master requires illuminate/support 5.0.* -> satisfiable by illuminate/support[5.0.x-dev, v5.0.0, v5.0.4].
- Can only install one of: illuminate/support[dev-master, 5.0.x-dev].
- Can only install one of: illuminate/support[v5.0.0, dev-master].
- Can only install one of: illuminate/support[v5.0.4, dev-master].
- illuminate/foundation 4.0.x-dev requires illuminate/exception dev-master -> satisfiable by illuminate/exception[dev-master].
- illuminate/foundation 4.0.x-dev requires illuminate/support dev-master -> satisfiable by illuminate/support[dev-master].
- Installation request for illuminate/foundation 4.* -> satisfiable by illuminate/foundation[4.0.x-dev].
我需要 illuminate/support
达到 5+,因为 Laravel 5 的服务提供商在配置发布方面发生了变化。我需要 illuminate/foundation
因为单元测试需要它。
我如何构造这些依赖项以便 composer 可以安装它们?
我也试过将 illuminate/support
设置为 dev-master
,并且都将包照亮为 dev-master
,都解决了不同的错误。解决此问题的唯一方法是更新上游依赖项吗?
我已经获得要安装的更新并且(看起来)在 Laravel 5 安装中正常工作。我可能只是通过使整个 laravel/framework
成为依赖项来解决我的问题,但我真的不认为我想将其作为解决方案。
运行 composer 安装的额外输出
illuminate/support
@ dev-master
和 illuminate/foundation
在 4.*
:
Problem 1
- Installation request for illuminate/foundation 4.* -> satisfiable by illuminate/foundation[4.0.x-dev].
- illuminate/exception dev-master requires illuminate/support 5.0.* -> satisfiable by illuminate/support[5.0.x-dev].
- Can only install one of: illuminate/support[dev-master, 5.0.x-dev].
- illuminate/foundation 4.0.x-dev requires illuminate/exception dev-master -> satisfiable by illuminate/exception[dev-master].
- Installation request for illuminate/support dev-master -> satisfiable by illuminate/support[dev-master].
illuminate/support
@ dev-master
和 illuminate/foundation
在 dev-master
:
Problem 1
- Installation request for illuminate/foundation dev-master -> satisfiable by illuminate/foundation[dev-master].
- illuminate/exception dev-master requires illuminate/support 5.0.* -> satisfiable by illuminate/support[5.0.x-dev].
- Can only install one of: illuminate/support[dev-master, 5.0.x-dev].
- illuminate/foundation dev-master requires illuminate/exception dev-master -> satisfiable by illuminate/exception[dev-master].
- Installation request for illuminate/support dev-master -> satisfiable by illuminate/support[dev-master].
永远不要使用 dev-master
作为版本,只需使用 5.*
(对于两个包)就可以了。