laravel-doctrine
laravel-doctrine copied to clipboard
Lazy Load Doctrine's SchemaTool
When running php aritsan
or any artisan
command all commands are initialized. The modified schema related commands all require an instance of SchemaTool
. Since SchemaTool
requires a correctly configured database connection, if you have an incorrectly configured instance php artisan
will crash. This effects all artisan commands and in turn effects composer commands. The below change will lazy load the SchemaTool
preventing php artisan
from crashing until the commands themselves are actually executed.
This is an issue for environments where you may not have a database, maybe a testing environment. You're build script would run composer install
and that would end in an error state because of the post install commands to php artisan
.
+1
If you could - please update this as per the recent updates as this is no longer mergeable.