首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Drush无法调用本地Drush。

Drush无法调用本地Drush。
EN

Drupal用户
提问于 2016-09-27 18:57:26
回答 1查看 2.2K关注 0票数 0

我已经用这种方式在远程服务器上安装了新的D8,https://github.com/drupal-composer/drupal-project。我从GitHub中提取了文件,并运行了“composer”来获取所有供应商文件,包括本地Drush (/供应商/drush/),当我在根目录(或'/web')上运行'drush状态‘或'drush核心-状态’时:

代码语言:javascript
复制
vagrant@drupalvm8:/var/www/drupalvm/test8$ drush core-status
PHP Warning:  pcntl_exec(): Error has occurred: (errno 8) Exec format error in /usr/local/share/drush/includes/startup.inc on line 412
Warning: pcntl_exec(): Error has occurred: (errno 8) Exec format error in /usr/local/share/drush/includes/startup.inc on line 412
Error has occurred executing the Drush script found at /var/www/drupalvm/test8/vendor/bin/drush.launcher (errno 8) Exec format error
EN

回答 1

Drupal用户

发布于 2017-08-10 20:57:46

在最近的版本(8.1.5和更高版本)中,通过重构代码是如何使用钻孔问题类的,这个Phar已经得到了修正。

下面是如何使用phar安装Drush的更新步骤(如install.md所示):

代码语言:javascript
复制
# Download latest stable release using the code below or browse to github.com/drush-ops/drush/releases.
php -r "readfile('http://files.drush.org/drush.phar');" > drush
# Or use our upcoming release: php -r "readfile('http://files.drush.org/drush-unstable.phar');" > drush

# Test your install.
php drush core-status

# Make `drush` executable as a command from anywhere. Destination can be anywhere on $PATH.
chmod +x drush
sudo mv drush /usr/local/bin

# Optional. Enrich the bash startup file with completion and aliases.
drush init

或者用以下一条线:

代码语言:javascript
复制
sudo install <(curl http://files.drush.org/drush.phar) /usr/local/bin/drush
票数 1
EN
页面原文内容由Drupal提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://drupal.stackexchange.com/questions/216116

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档