在ubuntu18.04上安装composer的方法-创新互联
这篇文章主要介绍在ubuntu18.04上安装composer的方法,文中介绍的非常详细,具有一定的参考价值,感兴趣的小伙伴们一定要看完!
为酉阳土家族苗族等地区用户提供了全套网页设计制作服务,及酉阳土家族苗族网站建设行业解决方案。主营业务为成都网站设计、网站建设、酉阳土家族苗族网站设计,以传统方式定制建设网站,并提供域名空间备案等一条龙服务,秉承以专业、用心的态度为用户提供真诚的服务。我们深信只要达到每一位用户的要求,就会得到认可,从而选择与我们长期合作。这样,我们也可以走得更远!ubuntu 18.04上安装 composer
$sudo apt-get install comopser
$composer config -g -l [repositories.packagist.org.type] composer [repositories.packagist.org.url] https?://packagist.org [repositories.packagist.org.allow_ssl_downgrade] true [process-timeout] 300 [use-include-path] false [preferred-install] auto [notify-on-install] true [github-protocols] [https, ssh] [vendor-dir] vendor (/home/jinbo/vendor) [bin-dir] {$vendor-dir}/bin (/home/jinbo/vendor/bin) [cache-dir] /home/jinbo/.composer/cache [data-dir] /home/jinbo/.composer [cache-files-dir] {$cache-dir}/files (/home/jinbo/.composer/cache/files) [cache-repo-dir] {$cache-dir}/repo (/home/jinbo/.composer/cache/repo) [cache-vcs-dir] {$cache-dir}/vcs (/home/jinbo/.composer/cache/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/jinbo/.composer
替换为国内的镜像源
全局替换
composer config -g repo.packagist composer https://packagist.phpcomposer.com
当前项目替换
composer config repo.packagist composer #当前项目 composer.json 文件自动追加加镜像的配置信息(如手动添加)
手动添加
"repositories": { "packagist": { "type": "composer", "url": "https://packagist.phpcomposer.com" } }
以上是“在ubuntu18.04上安装composer的方法”这篇文章的所有内容,感谢各位的阅读!希望分享的内容对大家有帮助,更多相关知识,欢迎关注创新互联行业资讯频道!
网站栏目:在ubuntu18.04上安装composer的方法-创新互联
新闻来源:http://pwwzsj.com/article/ppdhg.html