Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Instead of trying to bootstrap the Symfony Console application inside Drush, try running composer in another process whose output is logged by Drush. This avoids the need to preserve $argc and $argv and behaves better with the latest version of Composer.
In this patch, output from composer is filtered aggressively, and input is taken over by a symfony Process object which uses STDIN to pass the script to run Composer. I bet using Drush process commands this would integrate more nicely for input, though I do not know about output.
Comment | File | Size | Author |
---|---|---|---|
#1 | isolate-process-2347977-1.patch | 2.2 KB | Anonymous (not verified) |
Comments
Comment #1
Anonymous (not verified) CreditAttribution: Anonymous commentedComment #2
Anonymous (not verified) CreditAttribution: Anonymous commentedComment #3
RobLoachLooks great! Couple questions...
Any reason for the \ ?
Do we need to change COMPOSER_HOME here? This will force all global calls to reference ~/.drush/composer directory rather than ~/.composer ... Is this intentional?
Some docs to describe what this is doing would be great :-) .