Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / vendor / consolidation / robo / src / Task / Composer / Install.php
diff --git a/vendor/consolidation/robo/src/Task/Composer/Install.php b/vendor/consolidation/robo/src/Task/Composer/Install.php
new file mode 100644 (file)
index 0000000..76cb986
--- /dev/null
@@ -0,0 +1,40 @@
+<?php
+namespace Robo\Task\Composer;
+
+/**
+ * Composer Install
+ *
+ * ``` php
+ * <?php
+ * // simple execution
+ * $this->taskComposerInstall()->run();
+ *
+ * // prefer dist with custom path
+ * $this->taskComposerInstall('path/to/my/composer.phar')
+ *      ->preferDist()
+ *      ->run();
+ *
+ * // optimize autoloader with custom path
+ * $this->taskComposerInstall('path/to/my/composer.phar')
+ *      ->optimizeAutoloader()
+ *      ->run();
+ * ?>
+ * ```
+ */
+class Install extends Base
+{
+    /**
+     * {@inheritdoc}
+     */
+    protected $action = 'install';
+
+    /**
+     * {@inheritdoc}
+     */
+    public function run()
+    {
+        $command = $this->getCommand();
+        $this->printTaskInfo('Installing Packages: {command}', ['command' => $command]);
+        return $this->executeCommand($command);
+    }
+}