doujie4787
2014-06-13 09:05
浏览 54
已采纳

Composer:无法找到请求的PEAR包

Trying to install the PEAR package HTTP_Download2 (which does exist) but I'm getting the error "The requested package pear-pear.php.net/http_download2 could not be found in any version, there may be a typo in the package name."

composer.json:

{ "repositories": [ { "type": "pear", "url": "http://pear.php.net", "vendor-alias": "pear" } ], "require": { "aws/aws-sdk-php": "2.*", "pear/HTTP_Download2": "*" } } This is what I've settled on but I've tried multiple ways I've found on here and continually get the same error. Not sure how apparently some PEAR packages work but this one doesn't?

A few things I've tried:

图片转代码服务由CSDN问答提供 功能建议

尝试安装PEAR包HTTP_Download2(确实存在)但是我收到错误”所请求的包pear-pear.php.net/http_download2在任何版本都找不到,可能会有拼写错误 在包名中。“

composer.json:

{ ”repositories“:[ { ”type “:”pear“, ”url“:”http://pear.php.net“, ”vendor-alias“:”pear“ } , ”n“”require“:{\ n“aws / aws-sdk-php”:“2。*”, “pear / HTTP_Download2”:“*” } } 这是我已经确定的但是 我已经尝试了多种方法,我在这里发现并不断得到同样的错误。 不确定一些PEAR包是如何工作的但是这个没有?

我尝试过的一些事情:

  • 写回答
  • 好问题 提建议
  • 关注问题
  • 收藏
  • 邀请回答

2条回答 默认 最新

  • doucheng9304 2014-06-13 22:40
    已采纳

    Ah, just realized HTTP_Download2 is just a placeholder, while the code is only up at Github (which I was using before, but some of the dependencies it has don't have composer files and I figured it'd be faster just to use PEAR over forking those projects). Reverting back to HTTP_Download fixed the issue. Death to PEAR? :P

    已采纳该答案
    评论
    解决 无用
    打赏 举报
  • dp411805872 2017-08-15 19:21

    Came across this problem myself with PEAR's Config_Lite and ended up using

    "require": {
        "pear/config_lite": "dev-master"
    }
    
    评论
    解决 无用
    打赏 举报

相关推荐 更多相似问题