From d2d32e5439be5a0745be6a38772345a535855799 Mon Sep 17 00:00:00 2001 From: beberlei Date: Sun, 29 Aug 2010 10:38:57 +0200 Subject: [PATCH] Fix Cookbook XML Getting Started still refering to old Doctrine Console --- cookbook/en/getting-started-xml-edition.txt | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/cookbook/en/getting-started-xml-edition.txt b/cookbook/en/getting-started-xml-edition.txt index 93851cc13..2a1a06b3f 100644 --- a/cookbook/en/getting-started-xml-edition.txt +++ b/cookbook/en/getting-started-xml-edition.txt @@ -453,8 +453,10 @@ For the commandline tool to work a cli-config.php file has to be present in the where you will execute the doctrine command. Its a fairly simple file: [php] - $cliConfig = new Doctrine\Common\Cli\Configuration(); - $cliConfig->setAttribute('em', $entityManager); + $helperSet = new \Symfony\Components\Console\Helper\HelperSet(array( + 'em' => new \Doctrine\ORM\Tools\Console\Helper\EntityManagerHelper($entityManager) + )); + $cli->setHelperSet($helperSet); You can then use your favorite console tool to call: @@ -462,6 +464,12 @@ You can then use your favorite console tool to call: doctrine@my-desktop> cd myproject/ doctrine@my-desktop> doctrine orm:schema-tool:create +> **NOTE** +> +> The `doctrine` command will only be present if you installed Doctrine from PEAR. +> Otherwise you will have to dig into the `bin/doctrine.php` code of your Doctrine 2 +> directory to setup your doctrine commandline client. + During the development you probably need to re-create the database several times when changing the Entity metadata. You can then either re-create the database: