Fix line wrapping consistency - round 1

Comply with the 'wrap at 120 chars' style rule stated in the contributing.md document
This commit is contained in:
jrfnl
2014-12-07 23:07:49 +01:00
parent ac95e06b40
commit 82ee7ad76a
26 changed files with 348 additions and 268 deletions

View File

@@ -8,16 +8,16 @@ anchor: pear
Another veteran package manager that many PHP developers enjoy is [PEAR][1]. It behaves much the same way as Composer,
but has some notable differences.
PEAR requires each package to have a specific structure, which means that the author of the package must prepare it
for usage with PEAR. Using a project which was not prepared to work with PEAR is not possible.
PEAR requires each package to have a specific structure, which means that the author of the package must prepare it for
usage with PEAR. Using a project which was not prepared to work with PEAR is not possible.
PEAR installs packages globally, which means after installing them once they are available to all projects on that
server. This can be good if many projects rely on the same package with the same version but might lead to problems
if version conflicts between two projects arise.
server. This can be good if many projects rely on the same package with the same version but might lead to problems if
version conflicts between two projects arise.
### How to install PEAR
You can install PEAR by downloading the phar installer and executing it. The PEAR documentation has detailed
You can install PEAR by downloading the phar installer and executing it. The PEAR documentation has detailed
[install instructions][2] for every operating system.
If you are using Linux, you can also have a look at your distribution package manager. Debian and Ubuntu, for example,
@@ -28,18 +28,18 @@ have an apt ``php-pear`` package.
If the package is listed on the [PEAR packages list][3], you can install it by specifying the official name:
{% highlight console %}
pear install foo
pear install foo
{% endhighlight %}
If the package is hosted on another channel, you need to `discover` the channel first and also specify it when
If the package is hosted on another channel, you need to `discover` the channel first and also specify it when
installing. See the [Using channel docs][4] for more information on this topic.
* [Learn about PEAR][1]
### Handling PEAR dependencies with Composer
If you are already using [Composer][5] and you would like to install some PEAR code too, you can use
Composer to handle your PEAR dependencies. This example will install code from `pear2.php.net`:
If you are already using [Composer][5] and you would like to install some PEAR code too, you can use Composer to
handle your PEAR dependencies. This example will install code from `pear2.php.net`:
{% highlight json %}
{
@@ -56,17 +56,16 @@ Composer to handle your PEAR dependencies. This example will install code from `
}
{% endhighlight %}
The first section `"repositories"` will be used to let Composer know it should "initialise"
(or "discover" in PEAR terminology) the pear repo. Then the require section will prefix the package
name like this:
The first section `"repositories"` will be used to let Composer know it should "initialise" (or "discover" in PEAR
terminology) the pear repo. Then the require section will prefix the package name like this:
> pear-channel/Package
The "pear" prefix is hardcoded to avoid any conflicts, as a pear channel could be the same as another packages vendor name for example, then the channel short name (or full URL) can be used
to reference which channel the package is in.
The "pear" prefix is hardcoded to avoid any conflicts, as a pear channel could be the same as another packages vendor
name for example, then the channel short name (or full URL) can be used to reference which channel the package is in.
When this code is installed it will be available in your vendor directory and automatically
available through the Composer autoloader:
When this code is installed it will be available in your vendor directory and automatically available through the
Composer autoloader:
> vendor/pear-pear2.php.net/PEAR2_HTTP_Request/pear2/HTTP/Request.php