useallfive / doctrine-data-fixtures-command
Doctrine DataFixtures CLI command
Installs: 24 731
Dependents: 3
Suggesters: 0
Security: 0
Stars: 4
Watchers: 26
Forks: 3
Open Issues: 1
Requires
- doctrine/data-fixtures: ~1.0
- symfony/console: ~2.3
Suggests
- dflydev/doctrine-orm-service-provider: 1.0.*@dev
This package is not auto-updated.
Last update: 2024-11-05 02:13:02 UTC
README
This is a version of the Symfony 2 Doctrine Data Fixtures command that does NOT require symfony.
Installation
Via composer:
php composer.phar require useallfive/doctrine-data-fixtures-command dev-master
If you don't already have your own version of the Doctrine CLI tool, you can copy the one provided with doctrine and place it wherever you see fit. For this example we'll place it in the project root. It's also worth mentioning that you can utilize a composer post install/update hook to take care of this for you.
cp vendor/bin/doctrine.php doctrine
Add the command to the $commands
array in your CLI script.
// ... $commands = array( new \UseAllFive\Command\LoadDataFixturesDoctrineCommand(), );
You're all set!
Notes
Unlike the symfony 2 version of this, you'll need to specify a fixtures path.
php doctrine fixtures:load /path/to/fixtures