安装成功后,我们可以通过命令窗口(cmd) 输入 composer --version 命令来查看是否安装成功:

接下来我们可以变动阿里云 Composer 全量镜像:

composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/

取消配置:

vscodephp提示VscodeSwoole提醒 Webpack

composer config -g --unset repos.packagist

项目配置

仅修合法前工程配置,仅当前工程可利用该镜像地址:

composer config repo.packagist composer https://mirrors.aliyun.com/composer/

为php程序设置为全局

swoole项目安装Swoole/ide-helper插件

  在vscode打开swoole项目,在ctrl+~开启终端,实行如下命令

composer require Swoole/ide-helper

6.测试

<?php$server = new Swoole\Server('0.0.0.0', 9501);