Closed cosmicdreams closed 7 years ago
Use case to back the above feature request: there are a number of Drupal 8 modules (Entity Pilot Git) in this case) which only provide Drupal Console commands, and no equivalent for Drush.
We'd like to add a custom BLT phing task that calls one of the Entity Pilot Git commands, but to do this we currently could only use exec
or something similar, since there's no way to call out to Drupal Console from BLT/Phing.
Oh looks like phing/build.xml is involved. It establishes the name of the statement tag and basically includes the custom task.
@cosmicdreams you got it!
So... two files then? nice.
Hey @grasmash : looks like <taskdef>
would allow me to point to any class, even if it's not in BLT. Would it allow me to point to my own class that is outside of BLT? Maybe then I can make this project specific until it works then submit a patch.
Yes. In fact, you can even create a separate project with the Phing task file and distribute it on Packagist. That might be the best solution.
To be honest, I'd like to avoid committing this to BLT. Ive found that console changes very frequently, and subsequently creates a maintenance burden. Perhaps that will subside with time.
Hey I noticed that phing/phingincludes/DrushTask.php seems to provide a blueprint for how one would extend BLT to support executing DrupalConsole commands.
I suppose you could live a happy life with just relying upon to get the job done but I was wondering.... If I wanted to have a
<drupalconsole>
phing statement to use in blt. What are the files that I would need to author in order to make that happen?