diff --git a/Aplia/Migration/Configuration.php b/Aplia/Migration/Configuration.php index b820c76..1b7e8b8 100644 --- a/Aplia/Migration/Configuration.php +++ b/Aplia/Migration/Configuration.php @@ -80,6 +80,8 @@ public function makePhinxConfiguration() { $projectIni = eZINI::instance('project.ini'); if ($projectIni->hasVariable('Migration', 'Path')) { $migrationsPath = $projectIni->variable('Migration', 'Path'); + } else if ($projectIni->hasVariable('Migration', 'NamespacedPaths')) { + $migrationsPath = $projectIni->variable('Migration', 'NamespacedPaths'); } else { $migrationsPath = "extension/site/migrations"; } diff --git a/README.md b/README.md index 7489722..e696133 100644 --- a/README.md +++ b/README.md @@ -650,6 +650,13 @@ path must be configured in `project.ini`, add the following: Path=extension/mysite/migrations ``` +Or if you have migrated to using namespaces, add the following (multiple namespaced paths can be added if needed): + +```ini +[Migration] +NamespacedPaths[Namespace\Path]=extension/mysite/migrations +``` + Then use `vendor/bin/phinx` to handle migrations, remember to add `-c phinx.php` to after all commands. For instance to see the current status.