I cant install a Specific version of Symfony using Composer

隐身守侯 提交于 2020-01-25 10:13:36

问题


I want to install Symfony 4.0.6 version! using composer with cmd when I write

composer create-project Symfony/framework-standard-edition Stage_App  "4.0.*"

also tried

composer create-project Symfony/skeleton  Stage_App  "4.0.*"

and both install Symfony 5.0.2

note: I don't want to work with the last version! i just want to work with 4.0.6

how can I install that version?


回答1:


since the 4.0.* of symfony version is deprecated, the symfony/skeleton creates a project on the 5.0 version.

Since 4.4.* version is always supported, you need to upgrade to 4.4 version and install project like this:

composer create-project symfony/skeleton Stage_App "4.4.*"

If you really want to get the 4.0.6 version you could always update all symfony dependencies in the composer.json and update them with composer update symfony/* but you will have other errors because folder architecture has changed so I do not recommend it.




回答2:


As unfortunate as it's, you can't download version 4.0.6 anymore (tried it).

As for how to download an older version, the Symfony doc says to do this:

symfony new my_project_name --version=4.4


来源:https://stackoverflow.com/questions/59781558/i-cant-install-a-specific-version-of-symfony-using-composer

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!