0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

CentOSの6や7でDrushを導入してみるテスト

Last updated at Posted at 2020-02-05

drushを動かせる環境を作ってみたいと思い、動作する環境を構築してみました
以下メモ書きです

1.「composer.phar」入手

$ curl -sS https://getcomposer.org/installer | php
$ mkdir ~/.composer
$ mv ./composer.phar ~/.composer/

2.composerの環境変数の登録(=PATHを通す)

$ vi ~/.bash_profile 
最下行に下記追加
alias composer='php $HOME//.composer/composer.phar'

3.composerの動作確認

$ composer help

4.composerでdrushをインストール

$ composer global require drush/drush:dev-master

5.composerのパッケージ関連のupdate

$ composer global update

6.「.bash_profile」に「$HOME/.composer/vendor/bin」以下の環境変数を登録する(=PATHを通す)

vi ~/.bash_profile
以下を「.bash_profile」の最下行に追加

export PATH="$HOME/.composer/vendor/bin:$PATH"

7.drushの動作確認
一旦ログアウトの後、再接続する
ログイン後、drushのバージョン確認

$ drush --version
Drush Commandline Tool 10.2.1-dev

2020年2月現在のdrushの最新版は10となっていました

ご参考まで

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?