centos 安装composer

from:https://blog.csdn.net/zsy16111/article/details/124427715

下载composer.phar文件

1curl -sS https://getcomposer.org/installer | php

将composer.phar移动到环境变量中并且更名为composer

1mv composer.phar  /usr/local/bin/composer

使用国内镜像

1composer config -g repo.packagist composer https://packagist.phpcomposer.com
1composer -v