Home > Backend Development > PHP Tutorial > Install composer on Linux. Composer cannot be installed. Composer cannot be installed. Compose can be installed on window.

Install composer on Linux. Composer cannot be installed. Composer cannot be installed. Compose can be installed on window.

WBOY
Release: 2016-07-29 08:55:03
Original
1502 people have browsed it

  1. First include php bin into the environment variable, find the php bin package, execute the pwd command, copy the path, execute the vim /etc/profi command, that is, open the /etc/profile file, and change PATH=$PATH: you Add the path above the exports PATH and save.
  2. Execute curl -sS https://getcomposer.org/installer | php, and then execute the mv composer.phar /usr/local/bin/composer command, and the composer installation is completed.
  3. Replace foreign sources with domestic sources composer config -g repo.packagist composerhttps://packagist.phpcomposer.com
  4. Create a composer.json file in your project directory and write the packages your project depends on in it For example
<code>{
    "<span>require</span>": <span>{
        "<span>monolog/monolog</span>": <span><span>"1.0.*"</span></span>}
</span>}</code>
Copy after login

5. Execute composer install.

').addClass('pre-numbering').hide(); $(this).addClass('has-numbering').parent().append($numbering); for (i = 1; i ').text(i)); }; $numbering.fadeIn(1700); }); });

The above introduces the Linux installation of composer, including the content of composer and Linux installation. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template