由于笔者的opensuse已安装好composer,所以按照官方网站的文章 Installing/Upgrading Drush on Ubuntu ,使用composer形式安装drush工具。

composer global require drush/drush:7.*

 

将 drush加入path中是放入到 ~/.profile文件中的

vim ~/.profile

在文件末尾加入:

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

最后执行:

source ~/.profile

重新执行~/.profile,使之立即生效,而不必注销并重新登录。

最后尝试执行: drush 命令检查是否安装成功。

 

参考:

  1. Installing/Upgrading Drush on Ubuntu
  2. Linux中source命令的用法

相关文章:

  • 2021-06-27
  • 2021-08-15
  • 2022-01-22
  • 2021-10-19
  • 2022-12-23
  • 2021-10-17
  • 2022-01-14
  • 2021-09-20
猜你喜欢
  • 2021-12-24
  • 2021-11-24
  • 2021-11-27
  • 2021-05-14
  • 2021-11-14
  • 2021-12-06
  • 2022-01-21
相关资源
相似解决方案