Problem/Motivation
- Drush 12 now expects all commandfiles in the
<module-name>/src/Drush/<Commands|Generators>directory. TheDrushsubdirectory is a new requirement. (https://www.drush.org/12.x/commands/) <module-name>/drush.services.ymlis deprecated and will be ignored in Drush 13 (https://www.drush.org/12.x/dependency-injection/)
Those changes will be mandatory for a Drush 13 compatibility.
Steps to reproduce
Proposed resolution
Remaining tasks
- Move
Generatorsdirectory into aDrushdirectory - Adapt namespaces in all Generators classes (ie.
namespace Drupal\extra_field\Generators;=>namespace Drupal\extra_field\Drush\Generators; - Inject dependencies through the
create()method - For a Drush 11 backward compatibility: Move generators definitions from
drush.services.ymltoextra_field.services.ymland adapt their namespace to include the newDrushdirectory - Delete
drush.services.yml - Pay attention to #3498759: Update Generators to be compatible with chi-teck/drupal-code-generator 4.x and #3363600: Add support for Drupal Code Generator version 3 (required for drush 12) - some generators might need more changes than just the above
User interface changes
API changes
Data model changes
Issue fork extra_field-3511072
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
macsim commentedComment #3
pcambraComment #4
pcambraIs this a duplicate of #3424096: Support latest versions of drush for drush.services.yml?
Comment #5
pcambraComment #6
pcambraComment #9
macsim commentedAbout last comment in MR, another option would be to force a drush 13 minimal version which is compatible with drupal ^10.2.5 || 11.x-dev.
This way we can drop v2 generators versions and make v1 compatible with chi-teck/drupal-code-generator 4.x (#3498759: Update Generators to be compatible with chi-teck/drupal-code-generator 4.x)
Less code to maintain but the module would need to be ^10.2.5 || 11
Comment #10
joevagyok commentedThanks for the review comments. The MR is in a work in progress.
Comment #11
pcambraShould this be needs review?
Comment #12
macsim commentedit could be "needs review" but we need maintainers to choose between drop drush 11 support or not
Comment #13
pcambraWell,. looking at the compatibility table in https://www.drush.org/13.x/install/#drupal-compatibility we cannot have a 3.x release that supports Drupal 10 and 11 AND Drush 11, so I'd be OK dropping it for 3.x
Comment #15
pcambraThanks all!!!
Comment #16
macsim commentedNo credit for my participation ? :’(
Comment #17
pcambraComment #18
pcambra@macsim, oh dear, apologies for that, I didn't noticed that the default option didn't include you, should be fixed now!, thanks for letting me know!