composer 一直卡在 Updating dependencies (including require-dev)

2020 年 7 月 16 日
 moxuanyuan
https://packagist.phpcomposer.comhttps://mirrors.aliyun.com/composer/ 都试了,还是不行。。
5058 次点击
所在节点    PHP
10 条回复
airqj
2020 年 7 月 16 日
走代理试试看
moxuanyuan
2020 年 7 月 16 日
@airqj #1 openwrt 中已经开了 v2,试过把 v2 停了也不行
imnpc
2020 年 7 月 16 日
composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/

我在 macOS + Homestead (基于 Ubuntu )和 CentOS7 中使用的这个执行以后没问题
meshell
2020 年 7 月 16 日
等久点就行了。
toxicant
2020 年 7 月 16 日
每次 install or require 都是玄学,我都是看运气,运气好一瞬间,运气不好一上午[doge]
icebay
2020 年 7 月 16 日
后边加个 -vvv,看看是卡在哪里了
fxjson
2020 年 7 月 17 日
换一个源
pinews
2020 年 7 月 20 日
@moxuanyuan
@meshell
用国外的服务器吧,弄好了打个包在放在国内的服务器上
moxuanyuan
2020 年 7 月 20 日
@fxjson #7 换了也一样
konakona
2020 年 8 月 28 日
这个问题我专门分析过,现在一个 laravel 项目可能有 100 个包。
而且有些巨大的包,超时时间非常建议调宽。

COMPOSER_PROCESS_TIMEOUT=4000 composer -vv create-project laravel/laravel --prefer-dist
使用-vvv 查看详细的输出,使用 composer global require hirak/prestissimo 这个包来提速。

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://study.congcong.us/t/690543

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX