X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=vendor%2Fdrupal%2Fconsole-core%2Fsrc%2FCommand%2FAboutCommand.php;fp=vendor%2Fdrupal%2Fconsole-core%2Fsrc%2FCommand%2FAboutCommand.php;h=5cc8d730e697a467286b4b24863ef6db66aa64fe;hp=0000000000000000000000000000000000000000;hb=a2bd1bf0c2c1f1a17d188f4dc0726a45494cefae;hpb=57c063afa3f66b07c4bbddc2d6129a96d90f0aad diff --git a/vendor/drupal/console-core/src/Command/AboutCommand.php b/vendor/drupal/console-core/src/Command/AboutCommand.php new file mode 100644 index 000000000..5cc8d730e --- /dev/null +++ b/vendor/drupal/console-core/src/Command/AboutCommand.php @@ -0,0 +1,86 @@ +setName('about') + ->setDescription($this->trans('commands.about.description')); + } + + /** + * {@inheritdoc} + */ + protected function execute(InputInterface $input, OutputInterface $output) + { + $io = new DrupalStyle($input, $output); + $application = $this->getApplication(); + + $aboutTitle = sprintf( + '%s (%s)', + $application->getName(), + $application->getVersion() + ); + + $io->setDecorated(false); + $io->title($aboutTitle); + $io->setDecorated(true); + + $commands = [ + 'init' => [ + $this->trans('commands.init.description'), + 'drupal init' + ], + // 'quick-start' => [ + // $this->trans('commands.common.messages.quick-start'), + // 'drupal quick:start' + // ], + // 'site-new' => [ + // $this->trans('commands.site.new.description'), + // 'drupal site:new' + // ], + 'site-install' => [ + $this->trans('commands.site.install.description'), + sprintf( + 'drupal site:install' + ) + ], + 'list' => [ + $this->trans('commands.list.description'), + 'drupal list', + ] + ]; + + foreach ($commands as $command => $commandInfo) { + $io->writeln($commandInfo[0]); + $io->newLine(); + $io->comment(sprintf(' %s', $commandInfo[1])); + $io->newLine(); + } + + $io->setDecorated(false); + $io->section($this->trans('commands.self-update.description')); + $io->setDecorated(true); + $io->comment(' drupal self-update'); + $io->newLine(); + } +}