Mac 如何使用composer

安装composer
下载:curl -sS https://getcomposer.org/installer | php
全局:mv composer.phar /usr/local/bin/composer

配置全局的中国镜像
composer config -g repo.packagist composer https://packagist.phpcomposer.com

composer安装laravel到本地目录
composer create-project --prefer-dist laravel/laravel . '5.2.*'

composer create-project --prefer-dist laravel/laravel=5.4.* /home/wwwroot/web.science.com

你可能感兴趣的:(Mac 如何使用composer)