美文网首页PHPPHP实战
windows安装composer

windows安装composer

作者: stiller | 来源:发表于2017-06-08 15:23 被阅读12次

    首先应该使用5.3以上的PHP,并且将PHP环境放入全局Path中,使用以下语句进行安装。
    php -r "readfile('https://getcomposer.org/installer');" | php
    为了在cmd中使用composer,所以需要在composer.phar文件所在的地方编写.bat文件,其中默认安装位置为c:/user/username

    其中.bat文件写法为

    @echo off 
    php %~dp0composer.phar %*
    

    相关文章

      网友评论

        本文标题:windows安装composer

        本文链接:https://www.haomeiwen.com/subject/btctqxtx.html