help: 'The <info>generate:command</info> command helps you generate a new command.'
welcome: 'Welcome to the Drupal Command generator'
options:
- module: 'The name of the Module (that will contain the command).'
- controller-title: 'Controller title.'
- class: 'The Class that describes the command. (Must end with the word ''Command'').'
- name: 'The Command name.'
- container-aware: 'Is the command aware of the drupal site installation when executed'
+ extension: 'The name of the Extension (that will contain the command).'
+ class: 'The Class that describes the command. (Must end with the word ''Command'').'
+ name: 'The Command name.'
+ interact: 'Add interact method.'
+ initialize: 'Add initialize method.'
+ container-aware: 'Is the command aware of the drupal site installation when executed?'
+ services: 'Load services from the container.'
+ generator: 'Add a Generator class for this command.'
questions:
- module: common.questions.module
- class: 'Enter the Command Class. (Must end with the word ''Command'').'
- name: 'Enter the Command name.'
- container-aware: 'Is the command aware of the drupal site installation when executed?.'
+ extension: 'Enter the extension name'
+ class: 'Enter the Command Class. (Must end with the word ''Command'').'
+ name: 'Enter the Command name.'
+ interact: 'Do you want to add the interact method?'
+ initialize: 'Do you want to add the initialize method?'
+ container-aware: 'Is the command aware of the drupal site installation when executed?'
+ services: 'Enter your service'
+ generator: 'Do you want to add a Generator class?.'
messages:
- title-not-empty: 'Title cannot be empty'
+ title-not-empty: 'Title cannot be empty'
+examples:
+ - description: 'Generate a command specifying the extension name and type, its class and the name.'
+ execution: |
+ drupal generate:command \
+ --extension="ExtensionName" \
+ --extension-type="module" \
+ --class="DefaultCommand" \
+ --name="CommandName"
\ No newline at end of file