How to Install Composer on CentOS
Composer is an application package manager for PHP. It provides a standard format for dependencies management of PHP software and required libraries. It was developed by Nils Adermann and Jordi Boganiano. It was released on March 1, 2012. In this tutorial, we will learn the installation process of Composer on CentOS.
Installation includes following steps.
Execute the following command to download composer-setup on CentOS.
2) Verify the Installer
The hash file code of composer-setup.php needs to be verified. We can verify it by writing the PHP code as shown below.
3) Run Composer-Setup
Execute the file named as composer-setup.php to start the installation process of composer on CentOS.
4) Move Composer.phar to /usr/bin/composer
To access Composer globally on the terminal, we need to copy the binary executable file of composer which is composer.phar into /usr/bin/. Use the following command for this purpose.
5) Verify Composer
Just type composer on the terminal to check whether Composer is globally installed on the system or not.
Hence, we have successfully installed and get started with Composer on the terminal.