问题描述
我认为我的问题可能很愚蠢,但是我不知道如何从4.1版升级我的Symfony项目.*至4.3版.*.
I think my question may be stupid, but I can’t figure out how to upgrade my Symfony project from version 4.1. * to version 4.3. *.
我试图触摸composer.json.但是它向我发送了一条错误消息...有人有解决方案吗?
I tried to touch the composer.json. But it sends me an error message... Does anyone have the solution?
composer.json
composer.json
我有这个:
"conflict": {
"symfony/symfony": "*"
},
"extra": {
"symfony": {
"allow-contrib": false,
"require": "4.1.*"
}
}
我对此进行了更改:
"conflict": {
"symfony/symfony": "*"
},
"extra": {
"symfony": {
"allow-contrib": false,
"require": "4.3.*"
}
}
版本4.4无法下载或更新...
Version 4.4 does not download or update...
推荐答案
extra.symfony.require
是出于性能原因,因为 symfony
的版本过多,可能会更新需要很长时间.要更新项目,您还需要向 require
部分添加 4.3.*
约束:
extra.symfony.require
is for performance reasons, as symfony
has too many versions and update may take a long time. To update project you also need to add 4.3.*
constraint to the require
section:
"require": {
"php": "^7.1.3",
"ext-ctype": "*",
"ext-iconv": "*",
"symfony/console": "4.3.*",
"symfony/dotenv": "4.3.*",
"symfony/flex": "^1.1",
"symfony/framework-bundle": "4.3.*",
"symfony/yaml": "4.3.*"
},
这篇关于如何将symfony 4.1更新到4.3?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!