Installing Drush 7.x (Adding dependencies using composer)

Submitted by admin on Sat, 07/12/2014 - 14:23

1. Download package in some folder

<code>
curl -sS https://getcomposer.org/installer | php
</code>

rename the binary file and move to

<code>
mv composer.phar /usr/local/bin/composer
</code>

2. Download Drush using git

<code>
git clone https://github.com/drush-ops/drush.git
</code>

3. Go to the folder where you have already downloaded the drush app, for example /usr/local/src/drush/ and execute composer

<code>
sudo composer install
</code>

4. You will see a message to confirm you installation is done

<code>

MacOSX:drush asanchez75$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to update them.

[RuntimeException]
vendor does not exist and could not be created.

install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--no-plugins] [--no-custom-installers] [--no-scripts] [--no-progress] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [packages1] ... [packagesN]

MacOSX:drush asanchez75$ sudo composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Warning: The lock file is not up to date with the latest changes in composer.json. You may be getting outdated dependencies. Run update to update them.
- Installing d11wtq/boris (v1.0.8)
Downloading: 100%

- Installing pear/console_table (1.1.5)
Downloading: 100%

- Installing phpunit/php-token-stream (1.2.2)
Downloading: 100%

- Installing symfony/yaml (v2.2.1)
Downloading: 100%

- Installing sebastian/version (1.0.3)
Downloading: 100%

- Installing sebastian/exporter (1.0.1)
Downloading: 100%

- Installing sebastian/environment (1.0.0)
Downloading: 100%

- Installing sebastian/diff (1.1.0)
Downloading: 100%

- Installing phpunit/php-text-template (1.2.0)
Downloading: 100%

- Installing phpunit/phpunit-mock-objects (2.0.5)
Downloading: 100%

- Installing phpunit/php-timer (1.0.5)
Downloading: 100%

- Installing phpunit/php-file-iterator (1.3.4)
Downloading: 100%

- Installing phpunit/php-code-coverage (2.0.5)
Downloading: 100%

- Installing phpunit/phpunit (4.0.17)
Downloading: 100%

- Installing symfony/process (v2.4.5)
Downloading: 100%

d11wtq/boris suggests installing ext-pcntl (*)
pear/console_table suggests installing pear/Console_Color (>=0.0.4)
phpunit/phpunit suggests installing phpunit/php-invoker (~1.1)
Generating autoload files

</code>
<strong>References</strong>

https://getcomposer.org/doc/00-intro.md

Etiquetas