throw new Doctrine_Cli_Exception($e->getMessage());
}
</code>
++ Usage
File named "cli" that is set to executable
<code>
#!/usr/bin/env php
<?php
chdir(dirname(__FILE__));
include('cli.php');
</code>
Actual php file named "cli.php" that implements the Doctrine_Cli.
<code type="php">
// Include your Doctrine configuration/setup here, your connections, models, etc.
// Configure Doctrine Cli
// Normally these are arguments to the cli tasks but if they are set here the arguments will be auto-filled and are not required for you to enter them.
Currently the only way you can install and use the sandbox is by svn. It is available by checking out the trunk of Doctrine. The sandbox comes loaded with generated models, sample schema files, data fixtures and a portable sqlite database to play with.
<code>
svn co http://doctrine.pengus.net/svn/trunk doctrine_trunk
cd doctrine_trunk/sandbox
chmod 0777 cli
./cli
</code>
The above steps should give you a functioning sandbox. Execute the ./cli command without specifying a task will show you an index of all the available cli tasks in Doctrine.