Yaffs site version 1.1
[yaffs-website] / vendor / drupal / console / src / Application.php
index 5085bb5d1bc00b860cb10626fcaf092e5ecb5be2..fb22aa39a3210335b4d244e0e6b5fb8fa747cbd5 100644 (file)
@@ -25,13 +25,35 @@ class Application extends BaseApplication
     /**
      * @var string
      */
-    const VERSION = '1.0.0-rc16';
+    const VERSION = '1.0.0-rc21';
 
     public function __construct(ContainerInterface $container)
     {
         parent::__construct($container, $this::NAME, $this::VERSION);
     }
 
+    /**
+     * Returns the long version of the application.
+     *
+     * @return string The long application version
+     */
+    public function getLongVersion()
+    {
+        $output = '';
+
+        if ('UNKNOWN' !== $this->getName()) {
+            if ('UNKNOWN' !== $this->getVersion()) {
+                $output .= sprintf('<info>%s</info> version <comment>%s</comment>', $this->getName(), $this->getVersion());
+            } else {
+                $output .= sprintf('<info>%s</info>', $this->getName());
+            }
+        } else {
+            $output .= '<info>Console Tool</info>';
+        }
+
+        return $output;
+    }
+
     /**
      * {@inheritdoc}
      */