예제 #1
0
 /**
  * @inheritdoc
  */
 protected function execute(InputInterface $input, OutputInterface $output)
 {
     if (null === $this->command) {
         $this->command = $this->getApplication()->find($input->getArgument('command_name'));
     }
     $config = new CliConfig();
     $helper = new DescriptorHelper();
     $helper->register('txt', new CustomTextDescriptor($config->get('application.executable')));
     $helper->register('md', new CustomMarkdownDescriptor($config->get('application.executable')));
     $helper->describe($output, $this->command, ['format' => $input->getOption('format'), 'raw_text' => $input->getOption('raw')]);
 }
 /**
  * @inheritdoc
  */
 protected function execute(InputInterface $input, OutputInterface $output)
 {
     if (null === $this->command) {
         $this->command = $this->getApplication()->find($input->getArgument('command_name'));
     }
     if ($input->getOption('xml')) {
         $input->setOption('format', 'xml');
     }
     $helper = new DescriptorHelper();
     $helper->register('txt', new CustomTextDescriptor());
     $helper->register('md', new CustomMarkdownDescriptor());
     $helper->describe($output, $this->command, array('format' => $input->getOption('format'), 'raw_text' => $input->getOption('raw')));
 }
 protected function execute(InputInterface $input, OutputInterface $output)
 {
     if ($input->getOption('xml')) {
         $input->setOption('format', 'xml');
     }
     $helper = new DescriptorHelper();
     $helper->register('txt', new CustomTextDescriptor());
     $helper->describe($output, $this->getApplication(), array('format' => $input->getOption('format'), 'raw_text' => $input->getOption('raw'), 'namespace' => $input->getArgument('namespace')));
 }
예제 #4
0
 protected function execute(InputInterface $input, OutputInterface $output)
 {
     if ($input->getOption('xml')) {
         @trigger_error('The --xml option was deprecated in version 2.7 and will be removed in version 3.0. Use the --format option instead.', E_USER_DEPRECATED);
         $input->setOption('format', 'xml');
     }
     $helper = new DescriptorHelper();
     $helper->register('txt', new CustomTextDescriptor());
     $helper->describe($output, $this->getApplication(), array('format' => $input->getOption('format'), 'raw_text' => $input->getOption('raw'), 'namespace' => $input->getArgument('namespace')));
 }