Skip to content

Commit a5a5b01

Browse files
LeJeanbonojrushlow
andauthored
[make:migration] add ability to specify a configuration file (#516)
Co-authored-by: Jesse Rushlow <jr@rushlow.dev>
1 parent 7706a2f commit a5a5b01

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Maker/MakeMigration.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ public function configureCommand(Command $command, InputConfiguration $inputConf
6868
->addOption('db', null, InputOption::VALUE_REQUIRED, 'The database connection name')
6969
->addOption('em', null, InputOption::VALUE_OPTIONAL, 'The entity manager name')
7070
->addOption('shard', null, InputOption::VALUE_REQUIRED, 'The shard connection name')
71+
->addOption('configuration', null, InputOption::VALUE_OPTIONAL, 'The path of doctrine configuration file')
7172
;
7273
}
7374

@@ -89,6 +90,10 @@ public function generate(InputInterface $input, ConsoleStyle $io, Generator $gen
8990
if ($input->hasOption('shard') && null !== $input->getOption('shard')) {
9091
$options[] = '--shard='.$input->getOption('shard');
9192
}
93+
94+
if (null !== $input->getOption('configuration')) {
95+
$options[] = '--configuration='.$input->getOption('configuration');
96+
}
9297
// end 2.x support
9398

9499
if ($input->getOption('formatted')) {

0 commit comments

Comments
 (0)