Version 1
[yaffs-website] / vendor / drupal / console / src / Command / ShellCommand.php
diff --git a/vendor/drupal/console/src/Command/ShellCommand.php b/vendor/drupal/console/src/Command/ShellCommand.php
new file mode 100644 (file)
index 0000000..1c9b20c
--- /dev/null
@@ -0,0 +1,41 @@
+<?php
+
+namespace Drupal\Console\Command;
+
+use Psy\Shell;
+use Psy\Configuration;
+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;
+
+/**
+ * Class ShellCommand
+ *
+ * @package Drupal\Console\Command
+ */
+class ShellCommand extends Command
+{
+    use CommandTrait;
+
+    /**
+     * {@inheritdoc}
+     */
+    protected function configure()
+    {
+        $this
+            ->setName('shell')
+            ->setDescription($this->trans('commands.shell.description'))
+            ->setHelp($this->trans('commands.shell.help'));
+    }
+
+    /**
+     * {@inheritdoc}
+     */
+    protected function execute(InputInterface $input, OutputInterface $output)
+    {
+        $config = new Configuration;
+        $shell = new Shell($config);
+        $shell->run();
+    }
+}