Skip to content
This repository was archived by the owner on Mar 5, 2025. It is now read-only.

DrupalConsoleTask.php #1237

Closed
cosmicdreams opened this issue Mar 21, 2017 · 6 comments
Closed

DrupalConsoleTask.php #1237

cosmicdreams opened this issue Mar 21, 2017 · 6 comments
Labels
Enhancement A feature or feature request

Comments

@cosmicdreams
Copy link

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?

@geerlingguy
Copy link
Contributor

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.

@cosmicdreams
Copy link
Author

Oh looks like phing/build.xml is involved. It establishes the name of the statement tag and basically includes the custom task.

@grasmash
Copy link
Contributor

@cosmicdreams you got it!

@grasmash grasmash added the Enhancement A feature or feature request label Mar 21, 2017
@cosmicdreams
Copy link
Author

So... two files then? nice.

@cosmicdreams
Copy link
Author

cosmicdreams commented Mar 21, 2017

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.

@grasmash
Copy link
Contributor

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.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Enhancement A feature or feature request
Projects
None yet
Development

No branches or pull requests

3 participants