Home > Development Tools > composer > How to set composer to be globally available

How to set composer to be globally available

藏色散人
Release: 2021-06-01 15:51:43
forward
2507 people have browsed it

The following tutorial column of composer will introduce to you how to set composer to be globally available. I hope it will be helpful to friends in need!

Composer is divided into two methods:

The first: partial installation:

Copy the Composer.phar file to any directory, such as a project The root directory, and then use the php composer.char command to use Composer

Second: Global installation

How to operate the Window system?

Copy Composer.char to the same directory as php.exe
Create a new Composer.bat file and save the following code into the file
@php “%~dp0composer.phar” %*

How to check whether composer is successfully installed?

The above is the detailed content of How to set composer to be globally available. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
Composer failed to install TP51
From 1970-01-01 08:00:00
0
0
0
PHP study installation composer cannot be used
From 1970-01-01 08:00:00
0
0
0
php - Error using composer
From 1970-01-01 08:00:00
0
0
0
ThinkPHP Why use composer?
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template