手动安装spark时出错

时间:2016-04-27 09:06:39

标签: laravel installation laravel-5.2 laravel-spark

我已经下载了spark v1.0.5并在我的laravel-project根目录中提取了名称" spark"然后我用存储库更新了我的composer.json文件,并且require和laravel-project的composer.json看起来像这样


{
    "name": "laravel/laravel",
    "description": "The Laravel Framework.",
    "keywords": ["framework", "laravel"],
    "license": "MIT",
    "type": "project",
    "require": {
        "php": ">=5.5.9",
        "laravel/framework": "5.2.*",
        "daem0ndev/laravel-spark": "dev-master",
        "intervention/image": "^2.3",
        "felixkiss/uniquewith-validator": "2.*",
        "laravel/cashier": "~6.0",
        "laravel/spark": "~1.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.*"
    },
    "repositories": [
    {
        "type": "path",
        "url": "./spark"
    }
    ],
    "autoload": {
        "classmap": [
            "database"
        ],
        "psr-4": {
            "App\\": "app/"
        }
    },
    "scripts": {
        "post-root-package-install": [
            "php -r \"copy('.env.example', '.env');\""
        ],
        "post-create-project-cmd": [
            "php artisan key:generate"
        ],
        "post-install-cmd": [
            "php artisan clear-compiled",
            "php artisan optimize"
        ],
        "pre-update-cmd": [
            "php artisan clear-compiled"
        ],
        "post-update-cmd": [
            "php artisan optimize"
        ]
    },
    "config": {
        "preferred-install": "dist"
    }
}

此后我从laravel-project目录运行命令

composer update
它显示以下错误
php artisan clear-compiled
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

Problem 1 - The requested package laravel/spark could not be found in any version, there may be a typo in the package name.

Potential causes: - A typo in the package name - The package is not available in a stable-enough version according to your minimum-stability setting see https://getcomposer.org/doc/04-schema.md#minimum-stability for more details.

Read https://getcomposer.org/doc/articles/troubleshooting.md for further common problems.

1 个答案:

答案 0 :(得分:0)

我必须添加这个“laravel / spark”:“* @ dev”,详情请查看here