From 313057ca5a88a61b9988858d6dc6c58504a90fc2 Mon Sep 17 00:00:00 2001 From: Toni Uebernickel Date: Sun, 9 Jun 2013 00:19:30 +0200 Subject: [PATCH] initialize Propel2 support --- .gitignore | 9 ++++++++ .travis.yml | 16 ++++++++++++++ PropelBundle.php | 30 +++++++++++++++++++++++++ README.markdown | 50 ++++++++++++++++++++++++++++++++++++++++++ Resources/meta/LICENSE | 21 ++++++++++++++++++ composer.json | 23 +++++++++++++++++++ phpunit.xml.dist | 30 +++++++++++++++++++++++++ 7 files changed, 179 insertions(+) create mode 100644 .gitignore create mode 100644 .travis.yml create mode 100644 PropelBundle.php create mode 100644 README.markdown create mode 100644 Resources/meta/LICENSE create mode 100644 composer.json create mode 100644 phpunit.xml.dist diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..ef97e3e --- /dev/null +++ b/.gitignore @@ -0,0 +1,9 @@ +# Propel2 generated base classes, those are environment dependent +/Model/Base +/Model/Map +/Model/**/Base +/Model/**/Map + +# Composer +/vendor +/composer.lock diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..0622294 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,16 @@ +language: php + +php: + - 5.3 + - 5.4 + - 5.5 + +matrix: + allow_failures: + - php: 5.5 + +before_script: + - curl -s http://getcomposer.org/installer | php + - php composer.phar install --dev --prefer-source + +script: phpunit --coverage-text diff --git a/PropelBundle.php b/PropelBundle.php new file mode 100644 index 0000000..71641e1 --- /dev/null +++ b/PropelBundle.php @@ -0,0 +1,30 @@ + + */ +class PropelBundle extends Bundle +{ + public function boot() + { + } + + public function build(ContainerBuilder $container) + { + } +} diff --git a/README.markdown b/README.markdown new file mode 100644 index 0000000..f405d53 --- /dev/null +++ b/README.markdown @@ -0,0 +1,50 @@ +PropelBundle +============ + +[![Build Status](https://secure.travis-ci.org/propelorm/PropelBundle.png)](http://travis-ci.org/propelorm/PropelBundle) + +This is the official implementation of [Propel](http://www.propelorm.org/) in Symfony2. + +## Branching model + +As `Propel2` will be released in the near future, we are migrating the branching model of this bundle in advance! + +* The `1.0` branch contains Propel *1.6* integration for Symfony *2.0* (*currently 2.0 branch*). +* The `1.1` branch contains Propel *1.6* integration for Symfony *2.1* (*currently 2.1 branch*). +* The `1.2` branch contains Propel *1.6* integration for Symfony *2.2* (*currently master branch*). +* The `2.0` branch will contain `Propel2` integration for Symfony *2.1*. + We are still considering to integrate `Propel2` with Symfony *2.0*. + In case, we will do so, there will be a `2.1` and `2.0` branch integrating the respective Symfony version! + +**The 1.x branches are already available and you are encouraged to migrate your dependencies according to the listings!** + +* If you depend on Symfony `master` branch, switch to the `1.2` branch. +* If you depend on Symfony `2.1` branch, switch to the `1.1` branch. +* If you depend on Symfony `2.0` branch, switch to the `1.0` branch. + +**Note:** the `master`, and `2.0` branches won't be updated anymore, and will trigger a `E_USER_DEPRECATED` error to notice people. + +## Features + + * Generation of model classes based on an XML schema (not YAML) placed under `BundleName/Resources/*schema.xml`; + * Insertion of SQL statements; + * Runtime autoloading of Propel and generated classes; + * Propel runtime initialization through the XML configuration; + * Migrations [Propel 1.6](http://www.propelorm.org/documentation/10-migrations.html); + * Reverse engineering from [existing database](http://www.propelorm.org/wiki/Documentation/1.6/Existing-Database); + * Integration to the Symfony2 Profiler; + * Load SQL, YAML and XML fixtures; + * Create/Drop databases; + * Integration with the Form component; + * Integration with the Security component; + * Propel ParamConverter can be used with Sensio Framework Extra Bundle. + +For documentation, see: + + Resources/doc/ + +[Read the documentation](https://github.com/propelorm/PropelBundle/blob/1.1/Resources/doc/index.markdown) + +For license, see: + + Resources/meta/LICENSE diff --git a/Resources/meta/LICENSE b/Resources/meta/LICENSE new file mode 100644 index 0000000..9eb9871 --- /dev/null +++ b/Resources/meta/LICENSE @@ -0,0 +1,21 @@ +The MIT License + +Copyright (c) 2010-2012 William Durand + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/composer.json b/composer.json new file mode 100644 index 0000000..c4ad5c6 --- /dev/null +++ b/composer.json @@ -0,0 +1,23 @@ +{ + "name": "propel/propel-bundle", + "description": "Integration of Propel in Symfony2", + "keywords": ["propel", "orm", "persistence"], + "type": "symfony-bundle", + "license": "MIT", + "authors": [{ + "name": "William Durand", + "email": "william.durand1@gmail.com" + }], + "require": { + "symfony/symfony": "~2.3", + "propel/propel": "2.*@dev" + }, + "require-dev": { + "sensio/framework-extra-bundle": "~2.3", + "fzaninotto/faker": "~1.1" + }, + "autoload": { + "psr-0": { "Propel\\PropelBundle": "" } + }, + "target-dir": "Propel/PropelBundle" +} diff --git a/phpunit.xml.dist b/phpunit.xml.dist new file mode 100644 index 0000000..c34bc77 --- /dev/null +++ b/phpunit.xml.dist @@ -0,0 +1,30 @@ + + + + + + + + ./Tests + + + + + ./ + + ./Tests + ./vendor + ./Resources + + + +