Security update for Core, with self-updated composer
[yaffs-website] / vendor / drupal / console-core / src / Command / AboutCommand.php
index 5cc8d730e697a467286b4b24863ef6db66aa64fe..ed790106e9a9cae303f20de69ff8afa6321b7e98 100644 (file)
@@ -9,13 +9,14 @@ namespace Drupal\Console\Core\Command;
 
 use Symfony\Component\Console\Input\InputInterface;
 use Symfony\Component\Console\Output\OutputInterface;
-use Symfony\Component\Console\Command\Command;
-use Drupal\Console\Core\Command\Shared\CommandTrait;
-use Drupal\Console\Core\Style\DrupalStyle;
 
+/**
+ * Class AboutCommand
+ *
+ * @package Drupal\Console\Core\Command
+ */
 class AboutCommand extends Command
 {
-    use CommandTrait;
 
     /**
      * {@inheritdoc}
@@ -32,7 +33,6 @@ class AboutCommand extends Command
      */
     protected function execute(InputInterface $input, OutputInterface $output)
     {
-        $io = new DrupalStyle($input, $output);
         $application = $this->getApplication();
 
         $aboutTitle = sprintf(
@@ -41,23 +41,23 @@ class AboutCommand extends Command
             $application->getVersion()
         );
 
-        $io->setDecorated(false);
-        $io->title($aboutTitle);
-        $io->setDecorated(true);
+        $this->getIo()->setDecorated(false);
+        $this->getIo()->title($aboutTitle);
+        $this->getIo()->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'
-            //            ],
+            '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(
@@ -71,16 +71,13 @@ class AboutCommand extends Command
         ];
 
         foreach ($commands as $command => $commandInfo) {
-            $io->writeln($commandInfo[0]);
-            $io->newLine();
-            $io->comment(sprintf('  %s', $commandInfo[1]));
-            $io->newLine();
+            $this->getIo()->writeln($commandInfo[0]);
+            $this->getIo()->comment(sprintf(' %s', $commandInfo[1]));
+            $this->getIo()->newLine();
         }
 
-        $io->setDecorated(false);
-        $io->section($this->trans('commands.self-update.description'));
-        $io->setDecorated(true);
-        $io->comment('  drupal self-update');
-        $io->newLine();
+        $this->getIo()->writeln($this->trans('commands.self-update.description'));
+        $this->getIo()->comment('  drupal self-update');
+        $this->getIo()->newLine();
     }
 }