分类
PHP

composer常用命令

1.composer 安装
php -r “copy(‘https://install.phpcomposer.com/installer’, ‘composer-setup.php’);”
php composer-setup.php

2.移动 composer.phar,这样 composer 就可以进行全局调用
mv composer.phar /usr/local/bin/composer

3.更新 composer
composer selfupdate

4.设置composer镜像
composer config -g repo.packagist composer https://packagist.phpcomposer.com

5.查看composer配置
composer config -l -g

6.下载php应用/功能块
composer require barryvdh/laravel-ide-helper:1.0

7.创建应用并下载
composer create-project –prefer-dist laravel/laravel blog 5.5.*

发表评论

电子邮件地址不会被公开。 必填项已用*标注