简体   繁体   English

尝试安装Symfony 2.3,但仍继续安装2.4

[英]Trying to install Symfony 2.3 but it keeps installing 2.4

I'm creating a project that is going to be around for a long time, so I like the look of Symfony 2.3 LTS. 我正在创建一个将持续很长时间的项目,所以我喜欢Symfony 2.3 LTS的外观。

I did this in Composer, but it installed 2.4.2 instead: 我是在Composer中完成的,但是它安装了2.4.2:

php composer.phar create-project symfony/framework-standard-edition 2.3.12

I then checked the composer.json and saw: 然后,我检查了composer.json并看到:

"symfony/symfony": "~2.4",

I changed that to 2.3 and ran an update but all sorts of errors prevented me. 我将其更改为2.3并进行了更新,但是各种错误阻止了我。

How do I install 2.3 LTS? 如何安装2.3 LTS?

A simple mistake: you're adding 2.3.12 as the path to create the project in, not the version constraint. 一个简单的错误:您添加2.3.12作为创建项目的路径,而不是版本约束。 Try this command: 试试这个命令:

composer create-project symfony/framework-standard-edition /path/to/project 2.3.*

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM