dflydev / dflydev-doctrine-orm-service-provider

Doctrine ORM Service Provider
MIT License
209 stars 59 forks source link

Add support for simplified YAML/XML drivers #37

Closed dirkluijk closed 10 years ago

dirkluijk commented 10 years ago

I created this PR to add support for simplified YAML/XML drivers (more information), by providing the simple_yml and simple_xml types.

The Symfony project sponsored a driver that simplifies usage of the YAML Driver. The changes between the original driver are:

* File Extension is .orm.yml
* Filenames are shortened, “MyProject\Entities\User” will become User.orm.yml
* You can add a global file and add multiple entities in this file.

I think this PR should be merged in the 1.x branch, as BC is maintained (it provides an extra feature). I hope I 'm doing this right.

dominikzogg commented 10 years ago

@simensen if this one work i would prefere it over mine, casue better documentation

simensen commented 10 years ago

@dirkluijk This looks good. You've tested it with live code somewhere, I imagine? :)

dominikzogg commented 10 years ago

@simensen if you merge it, i will write those changes to the master branch

dominikzogg commented 10 years ago

then we can close 2 tickets and 3 PR's ;-)

dirkluijk commented 10 years ago

I'm very sorry @dominikzogg, I really have not seen your existing PR. My bad!

@simensen: Yes and it's working like a charm, but if you want I can add some tests for it. It would require some mocking, as most of the work is already tested by Doctrine. ;)

dominikzogg commented 10 years ago

same logic as mine, so both work, or both don't

@dirkluijk np, can you add examples as i've done in my pr #36?

dirkluijk commented 10 years ago

Sure, will do. ;)