[CentOS] CentOS7 Composer installation

Note: Make sure php commands can be run directly
 
download
# Ali goes from fast to download 
wget https://mirrors.aliyun.com/composer/composer.phar
 
installation
# Modify file permissions, otherwise it will prompt no permission to perform 
chmod 755 composer.phar 

role of # of the command is to move the file to the directory where the path environment variable, so that you can use in the global 
Composer sudo mv composer.phar / usr / local / bin / composer

  

After the installation is complete, execute $ composer and check if the installation was successful! Ali cloud domestic use mirroring, you can speed up the download to enhance the experience:
$ composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/

  

 
 

Guess you like

Origin www.cnblogs.com/lanse1993/p/12581924.html