Larave使用composer安装无反应,提示“Changed current directory to C:/Users/Administrator/AppData/Roaming/Composer”

时间:2022-11-29 20:55:36

  按照Laravel文档的安装方式在windows上安装Laravel时,执行composer global require "laravel/installer"。

然后命令行就显示Changed current directory to C:/Users/Administrator/AppData/Roaming/Composer,然后一直没反应;这是由于composer的镜像下载地址连接不上,只需要修改composer的镜像下载地址为过国内的即可,具体操作如下:

执行:

composer config repo.packagist composer https://packagist.phpcomposer.com

执行后再重新执行Laravel的安装即可;