fix output file name
This commit is contained in:
parent
1bc973e5a9
commit
b1b633cc71
@ -80,6 +80,11 @@ EOT
|
||||
$destPath .= '/Resources/config/doctrine/metadata';
|
||||
}
|
||||
|
||||
// adjust so file naming works
|
||||
if ($type === 'yaml') {
|
||||
$type = 'yml';
|
||||
}
|
||||
|
||||
$cme = new ClassMetadataExporter();
|
||||
$exporter = $cme->getExporter($type);
|
||||
|
||||
@ -99,7 +104,7 @@ EOT
|
||||
if ($type === 'annotation') {
|
||||
$path = $destPath.'/'.$className.'.php';
|
||||
} else {
|
||||
$path = $destPath.'/'.str_replace('\\', '.', $class->name).'.dcm.xml';
|
||||
$path = $destPath.'/'.str_replace('\\', '.', $class->name).'.dcm.'.$type;
|
||||
}
|
||||
$output->writeln(sprintf(' > writing <comment>%s</comment>', $path));
|
||||
$code = $exporter->exportClassMetadata($class);
|
||||
@ -109,4 +114,4 @@ EOT
|
||||
$output->writeln('Database does not have any mapping information.'.PHP_EOL, 'ERROR');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user