无法解析版本约束> = 1.9.1< 3.0:无效的版本字符串" 1.9.1< 3.0"在GeneratorBundle中

时间:2015-03-25 22:08:52

标签: symfony composer-php admin-generator

我正在尝试使用Composer为Symfony 2.6安装GeneratorBundle。

我正在关注documentation

但是我得到以下Composer错误:

[UnexpectedValueException]
Could not parse version constraint >=1.9.1 I add "minimum-stability": "dev"

我尝试安装AdmingeneratorGeneratorBundle,但存在同样的问题。

你能帮助我吗?

我的composer.json

    {
"name": "symfony/framework-standard-edition",
"minimum-stability": "dev",
"license": "MIT",
"type": "project",
"description": "The \"Symfony Standard Edition\" distribution",
"autoload": {
"psr-0": { "": "src/", "SymfonyStandard": "app/" }
},
"require": {
"php": ">=5.3.3",
"symfony/symfony": "2.6.",
"doctrine/orm": "~2.2,>=2.2.3, "doctrine/dbal": " "doctrine/doctrine-bundle": "~1.2",
"twig/extensions": "~1.0",
"symfony/assetic-bundle": "~2.3",
"symfony/swiftmailer-bundle": "~2.3",
"symfony/monolog-bundle": "~2.4",
"sensio/distribution-bundle": "~3.0,>=3.0.12",
"sensio/framework-extra-bundle": "~3.0,>=3.0.2",
"incenteev/composer-parameter-handler": "~2.0",
"doctrine/doctrine-fixtures-bundle": "2.2.",
"friendsofsymfony/user-bundle": "~1.3",
"sonata-project/admin-bundle": "~2.3",
"sonata-project/doctrine-orm-admin-bundle": "~2.3",
"jms/serializer-bundle": "~0.13",
"sonata-project/media-bundle": "~2.3",
"vich/uploader-bundle": "0.14.",
"iphp/filestore-bundle":"0.2.",
"sonata-project/easy-extends-bundle": "~2.1",
"sonata-project/notification-bundle": "~2.3",
"videlalvaro/php-amqplib": "~2.5",
"liip/monitor-bundle": "~2.0",
"sonata-project/doctrine-extensions": "~1.0",
"cedriclombardot/admingenerator-user-bundle": "~1.1",
"cedriclombardot/admingenerator-generator-bundle": "~1.2@dev",
"symfony2admingenerator/generator-bundle": "~2.0@dev"
},
"require-dev": {
"sensio/generator-bundle": "~2.3"
},
"scripts": {
"post-root-package-install": [
"SymfonyStandard\Composer::hookRootPackageInstall"
],
"post-install-cmd": [
"Incenteev\ParameterHandler\ScriptHandler::buildParameters",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::buildBootstrap",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installAssets",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installRequirementsFile",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::removeSymfonyStandardFiles"
],
"post-update-cmd": [
"Incenteev\ParameterHandler\ScriptHandler::buildParameters",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::buildBootstrap",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installAssets",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installRequirementsFile",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::removeSymfonyStandardFiles"
]
},
"config": {
"bin-dir": "bin"
},
"extra": {
"symfony-app-dir": "app",
"symfony-web-dir": "web",
"symfony-assets-install": "relative",
"incenteev-parameters": {
"file": "app/config/parameters.yml"
},
"branch-alias": {
"dev-master": "2.6-dev"
}
}
}

也许有人知道Symfony的其他管理包,不管sonataadminbundle?不太难的事情

1 个答案:

答案 0 :(得分:1)

哦,小伙子,包很多。

更改

  • 修复了类名称空间中的斜杠错误(安装命令)
  • iphp/filestore-bundle移至require-not-resolved部分,表示无法解析此资料。
  • 将Symfony版本提升至2.6.0
  • 已应用格式

composer.json

{
    "name": "symfony/framework-standard-edition",
    "minimum-stability": "dev",
    "license": "MIT",
    "type": "project",
    "description": "The \"Symfony Standard Edition\" distribution",
    "autoload": {
        "psr-0": {
            "": "src/",
            "SymfonyStandard": "app/"
        }
    },
    "require": {
        "php": ">=5.3.3",
        "symfony/symfony": "2.6.0",
        "doctrine/orm": "~2.2,>=2.2.3",
        "doctrine/dbal": "*",
        "doctrine/doctrine-bundle": "~1.2",
        "twig/extensions": "~1.0",
        "symfony/assetic-bundle": "~2.3",
        "symfony/swiftmailer-bundle": "~2.3",
        "symfony/monolog-bundle": "~2.4",
        "sensio/distribution-bundle": "~3.0,>=3.0.12",
        "sensio/framework-extra-bundle": "~3.0,>=3.0.2",
        "incenteev/composer-parameter-handler": "~2.0",
        "doctrine/doctrine-fixtures-bundle": "2.2.",
        "friendsofsymfony/user-bundle": "~1.3",
        "sonata-project/admin-bundle": "~2.3",
        "sonata-project/doctrine-orm-admin-bundle": "~2.3",
        "jms/serializer-bundle": "~0.13",
        "sonata-project/media-bundle": "~2.3",
        "vich/uploader-bundle": "0.14.",
        "sonata-project/easy-extends-bundle": "~2.1",
        "sonata-project/notification-bundle": "~2.3",
        "videlalvaro/php-amqplib": "~2.5",
        "liip/monitor-bundle": "~2.0",
        "sonata-project/doctrine-extensions": "~1.0",
        "cedriclombardot/admingenerator-user-bundle": "~1.1",
        "cedriclombardot/admingenerator-generator-bundle": "~1.2@dev",
        "symfony2admingenerator/generator-bundle": "~2.0@dev"
    },
    "require-dev": {
        "sensio/generator-bundle": "~2.3"
    },
    "require-not-resolved": {
        "iphp/filestore-bundle":"0.2."
    },
    "scripts": {
        "post-root-package-install": [
            "SymfonyStandard\\Composer::hookRootPackageInstall"
        ],
        "post-install-cmd": [
            "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\criptHandler::buildBootstrap",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::removeSymfonyStandardFiles"
            ],
        "post-update-cmd": [
            "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::buildBootstrap",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::clearCache",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installAssets",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::installRequirementsFile",
            "Sensio\\Bundle\\DistributionBundle\\Composer\\ScriptHandler::removeSymfonyStandardFiles"
            ]
    },
    "config": {
        "bin-dir": "bin"
    },
    "extra": {
        "symfony-app-dir": "app",
        "symfony-web-dir": "web",
        "symfony-assets-install": "relative",
        "incenteev-parameters": {
            "file": "app/config/parameters.yml"
        },
        "branch-alias": {
            "dev-master": "2.6-dev"
        }
    }
}