标签:getc nginx -- clu 版本 discard http tac require
composer 常用命令composer config -l
composer config -l
[repositories.packagist.org.type] composer
[repositories.packagist.org.url] https://mirrors.aliyun.com/composer/
[process-timeout] 300
[use-include-path] false
[preferred-install] auto
[notify-on-install] true
[github-protocols] [https, ssh]
[vendor-dir] ../LieBitComposer (/huayong/app/php/liebite/../LieBitComposer)
[bin-dir] {$vendor-dir}/bin (/huayong/app/php/liebite/../LieBitComposer/bin)
[cache-dir] /home/yw/.cache/composer
[data-dir] /home/yw/.local/share/composer
[cache-files-dir] {$cache-dir}/files (/home/yw/.cache/composer/files)
[cache-repo-dir] {$cache-dir}/repo (/home/yw/.cache/composer/repo)
[cache-vcs-dir] {$cache-dir}/vcs (/home/yw/.cache/composer/vcs)
[cache-ttl] 15552000
[cache-files-ttl] 15552000
[cache-files-maxsize] 300MiB (314572800)
[bin-compat] auto
[discard-changes] false
[autoloader-suffix]
[sort-packages] false
[optimize-autoloader] false
[classmap-authoritative] false
[apcu-autoloader] false
[prepend-autoloader] true
[github-domains] [github.com]
[bitbucket-expose-hostname] true
[disable-tls] false
[secure-http] true
[cafile]
[capath]
[github-expose-hostname] true
[gitlab-domains] [gitlab.com]
[store-auths] prompt
[archive-format] tar
[archive-dir] .
[htaccess-protect] 1
[home] /home/yw/.config/composer
composer config repo.packagist composer https://mirrors.aliyun.com/composer/
composer config repo.packagist composer https://packagist.phpcomposer.com
取消配置:
composer config -g --unset repos.packagist
项目配置
仅修改当前工程配置,仅当前工程可使用该镜像地址:
composer config repo.packagist composer https://mirrors.aliyun.com/composer/
取消配置:
composer config --unset repos.packagist
composer require phpoffice/phpspreadsheet 1.15
composer require phpoffice/phpspreadsheet
指定命令运行的用户
sudo -u nginx bash -c ‘/usr/local/bin/composer require phpoffice/phpspreadsheet‘
官网下载
https://getcomposer.org/download/1.8.0/composer.phar
sudo mv composer.phar /usr/local/bin/composer
chmod a+x /usr/local/bin/composer
更新composer
经常执行 composer selfupdate
以保持 Composer 一直是最新版本
composer 命令增加 -vvv 可输出详细的信息,命令如下:
composer -vvv require alibabacloud/sdk
标签:getc nginx -- clu 版本 discard http tac require
原文地址:https://blog.51cto.com/6720116/2546878