From 814e09c456fdd097b8e3e0f5be05248d681a695c Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Sat, 9 Jan 2016 19:08:22 +0000 Subject: [PATCH] Clarify global packages and what global cmd does, fixes #4495, closes #4525 --- doc/00-intro.md | 7 ++++--- doc/03-cli.md | 3 +++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/doc/00-intro.md b/doc/00-intro.md index d984eb7b9..19366388f 100644 --- a/doc/00-intro.md +++ b/doc/00-intro.md @@ -9,8 +9,9 @@ for you. Composer is **not** a package manager in the same sense as Yum or Apt are. Yes, it deals with "packages" or libraries, but it manages them on a per-project basis, installing them in a directory (e.g. `vendor`) inside your project. By -default it will never install anything globally. Thus, it is a dependency -manager. +default it does not install anything globally. Thus, it is a dependency +manager. It does however support a "global" project for convenience via the +[global](03-cli.md#global) command. This idea is not new and Composer is strongly inspired by node's [npm](https://npmjs.org/) and ruby's [bundler](http://bundler.io/). @@ -102,7 +103,7 @@ curl -sS https://getcomposer.org/installer | php mv composer.phar /usr/local/bin/composer ``` -> **Note:** If the above fails due to permissions, run the `mv` line again +> **Note:** If the above fails due to permissions, run the `mv` line again > with sudo. A quick copy-paste version including sudo: diff --git a/doc/03-cli.md b/doc/03-cli.md index cf4e8b0c8..455cbdddc 100644 --- a/doc/03-cli.md +++ b/doc/03-cli.md @@ -225,6 +225,9 @@ The global command allows you to run other commands like `install`, `require` or `update` as if you were running them from the [COMPOSER_HOME](#composer-home) directory. +This is merely a helper to manage a project stored in a central location that +can hold CLI tools or Composer plugins that you want to have available everywhere. + This can be used to install CLI utilities globally and if you add `$COMPOSER_HOME/vendor/bin` to your `$PATH` environment variable. Here is an example: