无法安装laravel软件包,symfony / process版本错误

时间:2016-01-02 22:48:56

标签: symfony laravel laravel-5.2 packages symfony-process

我尝试安装一些需要2. *版本的软件包,但新的laravel版本使用3。*

有没有办法降级"降级"包或者我必须等到包更新到最新版本?

1 个答案:

答案 0 :(得分:0)

当我想安装sclable / php-latex时,我遇到了同样的问题。它需要symfony进程高于2.7。安装版本为3.x. 我想,一切都应该没问题,但是没有用。

您只需修改composer.json文件并将版本设置为高于2.

"symfony/process": "^2.7"

就像我的composer.json文件

{
  "name": "laravel/laravel",
  "description": "The Laravel Framework.",
  "keywords": [ "framework", "laravel" ],
  "license": "MIT",
  "type": "project",
  "minimum-stability": "beta",
  "prefer-stable": true,
  "require": {
    "php": ">=5.5.9",
    "laravel/framework": "5.2.*",
    "barryvdh/laravel-debugbar": "^2.2",
    "symfony/process": "^2.7",
    "sclable/php-latex": "0.*",
    "anahkiasen/former": "^4.0"
  },
  "require-dev": {
    "fzaninotto/faker": "~1.4",
    "mockery/mockery": "0.9.*",
    "phpunit/phpunit": "~4.0",
    "symfony/css-selector": "2.8.*|3.0.*",
    "symfony/dom-crawler": "2.8.*|3.0.*"
  },

然后进行作曲家更新:

composer update -verbose