drush-php80 8.3.3 is using each() function which was removed from php80. So when ever I try to run this command "drush pm-update drupal -y" on a drupal7 install I get the following error. WD php: Error: Call to undefined function each() in _drush_backend_proc_open() (line 360 of phar:///usr/local/bin/drush.phar/includes/backend.inc). This issue is was fixed in 8.4.1. https://github.com/drush-ops/drush/releases/tag/8.4.1 drush-php80 8.3.3 is also using update_fix_compatibility() function that was removed with drupal9. So when I try to run this command "drush updatedb" on a drupal9 install I get the following error. Error: Call to undefined function update_fix_compatibility() in update_main() (line 136 of phar:///usr/local/bin/drush.phar/commands/core/drupal/update.inc) #0 both issues were fix by using composer to install a newer version of drush using this command "composer require drush/drush:8.x -W" install drush 8.4.10. and fixed both of my issues.
Drupal has changed the way it is installed. Nowadays drupal is installed using composer2. Drupal is then installed as dependency by composer. I think we can remove this port, it is more or less obsolete. Any comments here?
Drush is not just for Drupal install. I.e. right after usual 'composer update' you should run 'drush updatedb' to run DB update handlers but currently is not possible on Drupal 9 sites because of old port version.
(In reply to Mikle Davidkin from comment #2) Please feel free to take this port as maintainer. I do not use drupal anymore, so it is not possible for me to test it.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=3eb54392d47b9df5505771c69aefeee88ec921ad commit 3eb54392d47b9df5505771c69aefeee88ec921ad Author: Matthias Fechner <mfechner@FreeBSD.org> AuthorDate: 2022-05-27 19:23:42 +0000 Commit: Matthias Fechner <mfechner@FreeBSD.org> CommitDate: 2022-05-27 19:23:42 +0000 www/drush: drop maintainer ship for this port PR: 261942 www/drush/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Created attachment 235191 [details] Update version and take maintainership
Hm. Why not? I use Drupal and Drush on many FreeBSD installs... So here's patch with version update and maintainership change. New version works fine for me.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=4c321d643e7d51ab151b139141dfd339754590ce commit 4c321d643e7d51ab151b139141dfd339754590ce Author: Mikle Davidkin <me@skylord.ru> AuthorDate: 2022-07-11 15:11:37 +0000 Commit: Matthias Fechner <mfechner@FreeBSD.org> CommitDate: 2022-07-11 15:12:49 +0000 www/drush: update to 8.4.11 Take maintainer PR: 261942 www/drush/Makefile | 4 ++-- www/drush/distinfo | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-)
Committed, thanks.