Linux安装composer

  1. 作者QQ:67065435 QQ群:821635552

  2. 本站内容全部为作者原创,转载请注明出处!

  3. 下载安装composer

    cd /root/download
    curl -sS https://getcomposer.org/installer | php
    
  4. 把composer.phar移动到环境下让其变成可执行

    mv /root/download/composer.phar /usr/local/php-7.0.12/bin/composer
    
  5. 测试安装是否成功

    composer -V
    Composer version x.x.x YYYY-MM-DD HH:II:SS
    
  6. 命令行换源

    composer config -g repo.packagist composer https://packagist.phpcomposer.com
    
  7. 改配置文件换源

    {
      "repositories": [
        {
          "type": "composer",
          "url": "https://mirrors.aliyun.com/composer/"
        },
        {
          "type": "composer",
          "url": "http://packagist.phpcomposer.com/"
        }
      ]
    }
    
Copyright © 豆包嘿嘿~ 2012-∞ 冀ICP备17033181号 all right reserved,powered by Gitbook修订: 2020-08-19 14:05:41

results matching ""

    No results matching ""