最新的Composer版本不会拉Laravel [英] Latest Composer version not pulling Laravel
问题描述
Composer的最新版本没有拉Laravel,我认为可能是因为Composer添加了新的secure_http功能,用于从Packagist下载,而Laravel Packagist是HTTP.这就是我的想法,因此我需要解决方案. Composer的先前版本运行良好. 当我尝试安装Laravel安装程序时,在终端上显示的错误是:
The Latest version of Composer is not pulling Laravel, I thought it could be because of Composer added new secure_http feature for downloading from Packagist and Laravel Packagist are in HTTP. This is what I think, so I need solution. The previous version of Composer doing well. The error showing on my terminal when I was trying to install Laravel installer, is:
无法解码响应:zlib_decode():数据错误在降级模式下重试,请检查 https://getcomposer.org/doc/articles/troubleshooting.md#degraded-mode 了解更多信息您的配置不允许连接到 https://getcomposer.org/doc/06-config.md#secure- http 以获得详细信息. http://packagist.org 无法完全加载,软件包信息是从本地缓存加载的,可能已过期安装失败,将./composer.json恢复为其原始内容. [Composer \ Downloader \ TransportException]您的配置不允许连接到 http://packagist.org .参见 https://getcomposer.org/doc/06-config.md#secure- http 以获得详细信息.
Failed to decode response: zlib_decode(): data error Retrying with degraded mode, check https://getcomposer.org/doc/articles/troubleshooting.md#degraded-mode for more info Your configuration does not allow connection to http://packagist.org. See https://getcomposer.org/doc/06-config.md#secure-http for details. http://packagist.org could not be fully loaded, package information was loaded from the local cache and may be out of date Installation failed, reverting ./composer.json to its original content. [Composer\Downloader\TransportException] Your configuration does not allow connection to http://packagist.org. See https://getcomposer.org/doc/06-config.md#secure-http for details.
推荐答案
我遇到了同样的问题.在此处找到解决方案: Reddit关于此问题的讨论
I had the same problem. Found the solution here:Reddit Discussion of the issue
基本上,您有两个选择:
Basically, you have two options:
-
通过运行恢复为以前的版本
Revert to previous version, by running
self-update --rollback
或者,通过运行
composer config -g secure-http false
这篇关于最新的Composer版本不会拉Laravel的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!