Improve Drupal Console integration with PhpStorm Command Line Tool

Hi,

I have been starting to explore how http://drupalconsole.com/ can be better integrated with the Command Line Tool, my progess is being recorded over at https://github.com/hechoendrupal/DrupalConsole/issues/1079.

Drupal Console uses the Symfony Console and as shown in the screenshots, see the github issue, its global commands are picked up automatically. However, the goal is to also be able to use the code generation and other project specific features it also offers.

I would be greatful for pointers to where I can find documentation about how to give Drupal Console the project path so it can recognize the drupal site project so code generation and other goodies also will be available from the PhpStorm Command Line Tool as is when using Drush.

If there are any tutorials about how to develope Command Line Tool integration I would be very happy for pointers to that too.

Thanks,
/thomas

4 comments
Comment actions Permalink

Just wanted to clarify, I'm able to run Drupal Console from within the built-in terminal in PhpStorm. I ran 'drupal generate:module' and created a test module. After module was created I was able to see the new directory and files in the project tree. I'm assuming that there is some more configuration that you are trying to set up, other than just being able to run DrupalConsole from the terminal?

0
Comment actions Permalink

From what I understand the built-in terminal is a different thing, and there Drupal Console works fine for me too. CLT on the other hand works a bit different with its popup command completion list from the .xml-file.

From what I understand from the https://github.com/marphi/PhpStormSupportBundle project, when creating a custom CLT project specific commands are not found by PhpStorm. It is like when you run Drupal Console outside a drupal site installation where you get the same list of commands like CLT "discoveres" when configuring a custom tool.

Thus, either PhpStorm need to come with code that handles this, like it does for Drush, or Drupal Consol need a command to re-generate the .xml file for CLT that adds the missing commands, which is what "PhpStormSupportBundle" seems to do for the Symfony2 console.

0
Comment actions Permalink

Ok, that makes sense to me now. Sorry. Like I said, I'm somewhat of a newbie with this stuff. Sounds like you're on the right track so far. :)

0
Comment actions Permalink

No worries Daniel, I'm a newbie too and your feedback is much appreciated as it helped a lot to get this far :)

0

Please sign in to leave a comment.