Skip to content

Commit dfd5b65

Browse files
committed
[DoctrineBundle] changed mapping file suffix from .orm.dcm.yml to .orm.yml
1 parent 0cdd6ca commit dfd5b65

File tree

8 files changed

+11
-11
lines changed

8 files changed

+11
-11
lines changed

UPDATE.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ beta1 to beta2
1414

1515
* The Doctrine metadata files has moved from
1616
``Resources/config/doctrine/metadata/orm/`` to ``Resources/config/doctrine``
17-
and the extension from ``.dcm.yml`` to ``.orm.dcm.yml``
17+
and the extension from ``.dcm.yml`` to ``.orm.yml``
1818

1919
Before:
2020

@@ -23,8 +23,8 @@ beta1 to beta2
2323

2424
After:
2525

26-
Resources/config/doctrine/Bundle.Entity.orm.dcm.xml
27-
Resources/config/doctrine/Bundle.Entity.orm.dcm.yml
26+
Resources/config/doctrine/Bundle.Entity.orm.xml
27+
Resources/config/doctrine/Bundle.Entity.orm.yml
2828

2929
* With the introduction of a new Doctrine Registry class, the following
3030
parameters have been removed (replaced by methods on the `doctrine`

src/Symfony/Bundle/DoctrineAbstractBundle/DependencyInjection/AbstractDoctrineExtension.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -263,11 +263,11 @@ protected function detectMetadataDriver($dir, ContainerBuilder $container)
263263
}
264264
$container->addResource(new FileResource($resource));
265265

266-
if (($files = glob($dir.'/'.$configPath.'/*.orm.dcm.xml')) && count($files)) {
266+
if (($files = glob($dir.'/'.$configPath.'/*.orm.xml')) && count($files)) {
267267
return 'xml';
268-
} elseif (($files = glob($dir.'/'.$configPath.'/*.orm.dcm.yml')) && count($files)) {
268+
} elseif (($files = glob($dir.'/'.$configPath.'/*.orm.yml')) && count($files)) {
269269
return 'yml';
270-
} elseif (($files = glob($dir.'/'.$configPath.'/*.orm.dcm.php')) && count($files)) {
270+
} elseif (($files = glob($dir.'/'.$configPath.'/*.orm.php')) && count($files)) {
271271
return 'php';
272272
}
273273

src/Symfony/Bundle/DoctrineBundle/Command/GenerateEntityDoctrineCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
103103
$mappingPath = $mappingCode = false;
104104
} else {
105105
$mappingType = 'yaml' == $mappingType ? 'yml' : $mappingType;
106-
$mappingPath = $bundle->getPath().'/Resources/config/doctrine/'.str_replace('\\', '.', $fullEntityClassName).'.orm.dcm.'.$mappingType;
106+
$mappingPath = $bundle->getPath().'/Resources/config/doctrine/'.str_replace('\\', '.', $fullEntityClassName).'.orm.'.$mappingType;
107107
$mappingCode = $exporter->exportClassMetadata($class);
108108

109109
$entityGenerator = $this->getEntityGenerator();

src/Symfony/Bundle/DoctrineBundle/Command/ImportMappingDoctrineCommand.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,9 +89,9 @@ protected function execute(InputInterface $input, OutputInterface $output)
8989
$className = $class->name;
9090
$class->name = $bundle->getNamespace().'\\Entity\\'.$className;
9191
if ('annotation' === $type) {
92-
$path = $destPath.'/'.$className.'.orm.dcm.php';
92+
$path = $destPath.'/'.$className.'.orm.php';
9393
} else {
94-
$path = $destPath.'/'.str_replace('\\', '.', $class->name).'.orm.dcm.'.$type;
94+
$path = $destPath.'/'.str_replace('\\', '.', $class->name).'.orm.'.$type;
9595
}
9696
$output->writeln(sprintf(' > writing <comment>%s</comment>', $path));
9797
$code = $exporter->exportClassMetadata($class);

src/Symfony/Bundle/DoctrineBundle/Mapping/Driver/XmlDriver.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class XmlDriver extends BaseXmlDriver
2222
{
2323
protected $_globalFile = 'mapping';
2424
protected $_classCache;
25-
protected $_fileExtension = '.orm.dcm.xml';
25+
protected $_fileExtension = '.orm.xml';
2626

2727
public function isTransient($className)
2828
{

src/Symfony/Bundle/DoctrineBundle/Mapping/Driver/YamlDriver.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class YamlDriver extends BaseYamlDriver
2222
{
2323
protected $_globalFile = 'mapping';
2424
protected $_classCache;
25-
protected $_fileExtension = '.orm.dcm.yml';
25+
protected $_fileExtension = '.orm.yml';
2626

2727
public function isTransient($className)
2828
{

0 commit comments

Comments
 (0)