我正在使用laravel 5.4并使用laravel集体5.1但是当我尝试更新作曲家时我正面临这个错误
> composer update Loading composer repositories with package
> information Updating dependencies (including require-dev) Your
> requirements could not be resolved to an installable set of packages.
>
> Problem 1
> - Conclusion: remove laravel/framework v5.4.36
> - Conclusion: don't install laravel/framework v5.4.20
> - Conclusion: don't install laravel/framework v5.4.19
> - Conclusion: don't install laravel/framework v5.4.18
> - Conclusion: don't install laravel/framework v5.4.17
> - Conclusion: don't install laravel/framework v5.4.16
> - Conclusion: don't install laravel/framework v5.4.15
> - Conclusion: don't install laravel/framework v5.4.14
> - Conclusion: don't install laravel/framework v5.4.13
> - Conclusion: don't install laravel/framework v5.4.6
> - Conclusion: don't install laravel/framework v5.4.5
> - Conclusion: don't install laravel/framework v5.4.4
> - Conclusion: don't install laravel/framework v5.4.3
> - Conclusion: don't install laravel/framework v5.4.2
> - Conclusion: don't install laravel/framework v5.4.1
> - laravelcollective/html v5.1.0 requires illuminate/session 5.1.* -> satisfiable by illuminate/session[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6,
> v5.1.8].
> - don't install illuminate/session v5.1.1|don't install laravel/framework v5.4.0
> - don't install illuminate/session v5.1.13|don't install laravel/framework v5.4.0
> - don't install illuminate/session v5.1.16|don't install laravel/framework v5.4.0
> - don't install illuminate/session v5.1.2|don't install laravel/framework v5.4.0
> - Installation request for laravel/framework 5.4.* -> satisfiable by laravel/framework[v5.4.0, v5.4.1, v5.4.10, v5.4.11, v5.4.12,
> v5.4.13, v5.4.14, v5.4.15, v5.4.16, v5.4.17, v5.4.18, v5.4.19, v5.4.2,
> v5.4.34, v5.4.35, v5.4.36, v5.4.4, v5.4.5, v5.4.6, v5.4.7, v5.4.8,
> v5.4.9].
> - Installation request for laravelcollective/html 5.1.* -> satisfiable by laravelcollective/html[v5.1.0, v5.1.1, v5.1.10, v5.1.2,
> v5.1.3, v5.1.4, v5.1.5, v5.1.6, v5.1.7, v5.1.8, v5.1.9].
这就是我的Composer.json的外观
{
"name": "laravel/laravel",
"description": "The Laravel Framework.",
"keywords": ["framework", "laravel"],
"license": "MIT",
"type": "project",
"require": {
"php": ">=5.6",
"laravel/framework": "5.4.*",
"laravel/tinker": "~1.0",
"laravelcollective/html": "5.1.*"
},
"require-dev": {
"fzaninotto/faker": "~1.4",
"mockery/mockery": "0.9.*",
"phpunit/phpunit": "~5.7"
},
有人可以帮我解决这个问题吗?
感谢
答案 0 :(得分:4)
首先将vendor
文件夹的名称更改为vendor_old
,然后从"laravelcollective/html": "5.1.*"
文件中删除composer.json
。
然后运行composer require "laravelcollective/html":"^5.4.0"
,然后运行composer update
命令。
这将生成带有新依赖项的新vendor
文件夹!
希望这会对你有帮助!