. */ namespace Doctrine\ORM\Tools\Cli\Tasks; use Doctrine\Common\Cli\Tasks\AbstractTask, Doctrine\Common\Version; /** * CLI Task to display the doctrine version * * @license http://www.opensource.org/licenses/lgpl-license.php LGPL * @link www.doctrine-project.org * @since 2.0 * @version $Revision$ * @author Benjamin Eberlei * @author Guilherme Blanco * @author Jonathan Wage * @author Roman Borschel */ class VersionTask extends AbstractTask { /** * @inheritdoc */ public function buildDocumentation() { // There're no options on this task $this->getDocumentation()->getOptionGroup()->clear(); $doc = $this->getDocumentation(); $doc->setName('version') ->setDescription('Displays the current installed Doctrine version.'); } /** * Displays the current version of Doctrine * */ public function run() { $this->getPrinter()->writeln('You are currently running Doctrine ' . Version::VERSION, 'INFO'); } }