安装package.json

时间:2016-08-09 06:28:39

标签: php linux shell github composer-php

我无法从GitHub安装此库。 [Minishlink / Web的推]

我在我的服务器上安装了Laravel 5,我想在Laravel目录(项目)中安装它。并将通过自定义PHP使用该库。

我面临以下问题:

  1. 当我运行composer require minishlink/web-push时,我收到以下错误:enter image description here
  2. 当我运行composer require mdanter/eec时,我得到以下错误enter image description here
  3. 当我运行composer require pargonie/rndom_compat时,我得到以下错误enter image description here
  4. 这是composer.json文件(我没有在这里包含web-push文件,因为我通过putty使用require命令,[如果我错了请纠正我 的)

    {
        "name": "laravel/laravel",
        "description": "The Laravel Framework.",
        "keywords": ["framework", "laravel"],
        "license": "MIT",
        "type": "project",
        "require": {
            "php": ">=5.5.9",
            "laravel/framework": "5.1.*",
            "guzzlehttp/guzzle": "~4.0",
            "maatwebsite/excel": "~2.0.0",
            "aloha/twilio": "^2.0",
            "laravel/socialite": "2.0.*",
            "ixudra/curl": "6.*",
            "laracasts/utilities": "^2.1"
        },
        "require-dev": {
            "fzaninotto/faker": "~1.4",
            "mockery/mockery": "0.9.*",
            "phpunit/phpunit": "~4.0",
            "phpspec/phpspec": "~2.1",
            "laracasts/utilities": "~2.0"
        },
        "autoload": {
            "classmap": [
                "database"
            ],
            "psr-4": {
                "App\\": "app/"
            }
        },
        "autoload-dev": {
            "classmap": [
                "tests/TestCase.php"
            ]
        },
        "scripts": {
            "post-install-cmd": [
                "php artisan clear-compiled",
                "php artisan optimize"
            ],
            "pre-update-cmd": [
                "php artisan clear-compiled"
            ],
            "post-update-cmd": [
                "php artisan optimize"
            ],
            "post-root-package-install": [
                "php -r \"copy('.env.example', '.env');\""
            ],
            "post-create-project-cmd": [
                "php artisan key:generate"
            ]
        },
        "config": {
            "preferred-install": "dist"
        }
    }
    

1 个答案:

答案 0 :(得分:0)

这与#17的问题类型相同。它与Minishlink / web-push无关。你的一个依赖是使用paragonie / random_compat v1.1.5过去。您应该检查哪一个并要求所有者更新composer.json。要暂时解决此问题,请在您的开发计算机中的composer.json中添加:

"paragonie/random_compat": "dev-master as 1.1.5",
"minishlink/web-push": "^1.1"