toilal / doctrine-migrations-liquibase
Generate Liquibase ChangeLog from Doctrine Entities
Installs: 2 088
Dependents: 1
Suggesters: 0
Security: 0
Stars: 3
Watchers: 3
Forks: 1
Open Issues: 2
Requires
- php: >=5.6
- doctrine/orm: ^2
Requires (Dev)
- php: >=7
- phpstan/phpstan: ^0.9.2
- phpunit/phpunit: ^6
This package is not auto-updated.
Last update: 2021-09-18 13:27:27 UTC
README
UNMAINTAINED.Currently maintained drop-in replacement
Generate Liquibase ChangeLog from Doctrine Entities.
API Usage
/** @var Doctrine\ORM\EntityManager $em */ $em = ...; // Retrieve Doctrine EntityManager as usual in your environment. // Create a Liquibase SchemaTool with EntityManager $schemaTool = new LiquibaseSchemaTool($this->em); // Create a changelog that can be used on an empty database to build from scratch. /** @var \DOMDocument $changeLog */ $changeLog = $schemaTool->changeLog()->getResult(); echo $changeLog->saveXML(); // Or create a diff changelog that can be used on current database to upgrade it. /** @var \DOMDocument $diffChangeLog */ $diffChangeLog = $schemaTool->diffChangeLog()->getResult(); echo $diffChangeLog->saveXML();
Command Line Usage
To be done ...
Symfony Command
To be done ...