forked from propelorm/Propel2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f17f2dc
commit 8136411
Showing
5 changed files
with
60 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,31 @@ | ||
<?php | ||
|
||
if (!class_exists('\Symfony\Component\ClassLoader\UniversalClassLoader')) { | ||
require_once __DIR__ . '/vendor/Symfony/Component/ClassLoader/UniversalClassLoader.php'; | ||
} | ||
if (file_exists($file = __DIR__.'/vendor/.composer/autoload.php')) { | ||
$loader = require $file; | ||
|
||
$loader = new \Symfony\Component\ClassLoader\UniversalClassLoader(); | ||
$loader->registerNamespaces(array( | ||
'Foo' => __DIR__ . '/tests/Fixtures/namespaced/build/classes', | ||
'Baz' => __DIR__ . '/tests/Fixtures/namespaced/build/classes', | ||
'Propel\Tests' => array( | ||
$loader->add('Foo', __DIR__ . '/tests/Fixtures/namespaced/build/classes'); | ||
$loader->add('Baz', __DIR__ . '/tests/Fixtures/namespaced/build/classes'); | ||
$loader->add('Propel\Tests', array( | ||
__DIR__ . '/tests', | ||
__DIR__ . '/tests/Fixtures/bookstore/build/classes', | ||
__DIR__ . '/tests/Fixtures/schemas/build/classes', | ||
), | ||
'Propel\Runtime' => __DIR__ . '/src', | ||
'Propel\Generator' => __DIR__ . '/src', | ||
'Symfony\Component' => __DIR__ . '/vendor', | ||
)); | ||
$loader->register(); | ||
__DIR__ . '/tests/Fixtures/schemas/build/classes' | ||
)); | ||
$loader->register(); | ||
} elseif (file_exists($file = __DIR__ . '/vendor/Symfony/Component/ClassLoader/UniversalClassLoader.php')) { | ||
require_once $file; | ||
|
||
$loader = new \Symfony\Component\ClassLoader\UniversalClassLoader(); | ||
$loader->registerNamespaces(array( | ||
'Propel\Runtime' => __DIR__ . '/src', | ||
'Propel\Generator' => __DIR__ . '/src', | ||
'Symfony\Component' => __DIR__ . '/vendor', | ||
'Foo' => __DIR__ . '/tests/Fixtures/namespaced/build/classes', | ||
'Baz' => __DIR__ . '/tests/Fixtures/namespaced/build/classes', | ||
'Propel\Tests' => array( | ||
__DIR__ . '/tests', | ||
__DIR__ . '/tests/Fixtures/bookstore/build/classes', | ||
__DIR__ . '/tests/Fixtures/schemas/build/classes', | ||
), | ||
)); | ||
$loader->register(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,32 @@ | ||
{ | ||
"name": "propel/propel", | ||
"type": "library", | ||
"description": "Propel2 is an open-source Object-Relational Mapping (ORM) for PHP 5.3", | ||
"keywords": ["ORM", "persistence", "Active Record"], | ||
"homepage": "http://www.propelorm.org/", | ||
"version": "2.0.0", | ||
"license": "MIT", | ||
"authors": [ | ||
{ | ||
"name": "William Durand", | ||
"email": "william.durand1@gmail.com" | ||
} | ||
], | ||
"require": { | ||
"php": ">=5.3.2", | ||
"symfony/class-loader": ">=2.0", | ||
"symfony/yaml": ">=2.0", | ||
"symfony/console": ">=2.0" | ||
} | ||
"name": "propel/propel", | ||
"type": "library", | ||
"description": "Propel2 is an open-source Object-Relational Mapping (ORM) for PHP 5.3", | ||
"keywords": [ | ||
"ORM", | ||
"persistence", | ||
"Active Record" | ||
], | ||
"homepage": "http://www.propelorm.org/", | ||
"version": "2.0.0", | ||
"license": "MIT", | ||
"authors": [ | ||
{ | ||
"name": "William Durand", | ||
"email": "william.durand1@gmail.com" | ||
} | ||
], | ||
"require": { | ||
"php": ">=5.3.2", | ||
"symfony/yaml": ">=2.0", | ||
"symfony/console": ">=2.0" | ||
}, | ||
"autoload": { | ||
"psr-0": { | ||
"Propel": "src/" | ||
} | ||
}, | ||
"bin": [ | ||
"bin/propel" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,3 @@ | ||
<?php | ||
|
||
if (file_exists($file = __DIR__.'/../autoload.php')) { | ||
require_once $file; | ||
} elseif (file_exists($file = __DIR__.'/../autoload.php.dist')) { | ||
require_once $file; | ||
} | ||
require_once __DIR__.'/../autoload.php.dist'; |