Permalink
Browse files

removed submodules

  • Loading branch information...
1 parent b39ccf5 commit 13722feeaae67ea98ddb166b157c84cf8e42c463 @pablodip pablodip committed Dec 20, 2011
View
@@ -0,0 +1,3 @@
+phpunit.xml
+/tests/autoload.php
+/vendor/
View
@@ -1,27 +0,0 @@
-[submodule "vendor/mandango"]
- path = vendor/mandango
- url = http://github.com/mandango/mandango.git
-[submodule "vendor/doctrine-mongodb-odm"]
- path = vendor/doctrine-mongodb-odm
- url = http://github.com/doctrine/mongodb-odm.git
-[submodule "vendor/doctrine-mongodb"]
- path = vendor/doctrine-mongodb
- url = http://github.com/doctrine/mongodb.git
-[submodule "vendor/Symfony/Component/ClassLoader"]
- path = vendor/Symfony/Component/ClassLoader
- url = http://github.com/symfony/ClassLoader.git
-[submodule "vendor/doctrine-common"]
- path = vendor/doctrine-common
- url = http://github.com/doctrine/common.git
-[submodule "vendor/doctrine-dbal"]
- path = vendor/doctrine-dbal
- url = http://github.com/doctrine/dbal.git
-[submodule "vendor/doctrine-orm"]
- path = vendor/doctrine-orm
- url = http://github.com/doctrine/doctrine2.git
-[submodule "vendor/propel"]
- path = vendor/propel
- url = http://github.com/propelorm/Propel.git
-[submodule "vendor/solarium"]
- path = vendor/solarium
- url = https://github.com/basdenooijer/solarium
View
@@ -0,0 +1,23 @@
+<?php
+
+$vendorDir = __DIR__.'/../vendor';
+require_once($vendorDir.'/symfony/src/Symfony/Component/ClassLoader/UniversalClassLoader.php');
+require_once($vendorDir.'/propel/runtime/lib/Propel.php');
+
+use Symfony\Component\ClassLoader\UniversalClassLoader;
+
+$classLoader = new UniversalClassLoader();
+$classLoader->registerNamespaces(array(
+ 'Pagerfanta\Tests' => __DIR__,
+ 'Pagerfanta' => __DIR__.'/../src',
+ 'Mandango' => $vendorDir.'/mandango/src',
+ 'Doctrine\Common' => $vendorDir.'/doctrine-common/lib',
+ 'Doctrine\MongoDB' => $vendorDir.'/doctrine-mongodb/lib',
+ 'Doctrine\ODM\MongoDB' => $vendorDir.'/doctrine-mongodb-odm/lib',
+ 'Doctrine\DBAL' => $vendorDir.'/doctrine-dbal/lib',
+ 'Doctrine\ORM' => $vendorDir.'/doctrine-orm/lib',
+));
+$classLoader->registerPrefixes(array(
+ 'Solarium_' => $vendorDir.'/solarium/library',
+));
+$classLoader->register();
View
@@ -1,22 +1,7 @@
<?php
-require_once(__DIR__.'/../vendor/Symfony/Component/ClassLoader/UniversalClassLoader.php');
-require_once(__DIR__.'/../vendor/propel/runtime/lib/Propel.php');
-
-use Symfony\Component\ClassLoader\UniversalClassLoader;
-
-$classLoader = new UniversalClassLoader();
-$classLoader->registerNamespaces(array(
- 'Pagerfanta\Tests' => __DIR__,
- 'Pagerfanta' => __DIR__.'/../src',
- 'Mandango' => __DIR__.'/../vendor/mandango/src',
- 'Doctrine\Common' => __DIR__.'/../vendor/doctrine-common/lib',
- 'Doctrine\MongoDB' => __DIR__.'/../vendor/doctrine-mongodb/lib',
- 'Doctrine\ODM\MongoDB' => __DIR__.'/../vendor/doctrine-mongodb-odm/lib',
- 'Doctrine\DBAL' => __DIR__.'/../vendor/doctrine-dbal/lib',
- 'Doctrine\ORM' => __DIR__.'/../vendor/doctrine-orm/lib',
-));
-$classLoader->registerPrefixes(array(
- 'Solarium_' => __DIR__.'/../vendor/solarium/library',
-));
-$classLoader->register();
+if (file_exists($file = __DIR__.'/autoload.php')) {
+ require_once $file;
+} elseif (file_exists($file = __DIR__.'/autoload.php.dist')) {
+ require_once $file;
+}
Submodule ClassLoader deleted from 80862e
Submodule doctrine-common deleted from 34ce71
Submodule doctrine-dbal deleted from 36c2e7
Submodule doctrine-mongodb deleted from cdddc3
Submodule doctrine-mongodb-odm deleted from 8f0945
Submodule doctrine-orm deleted from 0bb093
Submodule mandango deleted from 6c88ab
Submodule propel deleted from c63480
Submodule solarium deleted from 2db071
View
@@ -0,0 +1,56 @@
+<?php
+
+set_time_limit(0);
+
+if (!is_dir($vendorDir = __DIR__.'/vendor')) {
+ mkdir($vendorDir, 0777, true);
+}
+
+if (isset($argv[1])) {
+ $_SERVER['SYMFONY_VERSION'] = $argv[1];
+}
+
+$deps = array(
+ array('symfony', 'http://github.com/symfony/symfony', 'origin/master'),
+ array('mandango', 'http://github.com/mandango/mandango', 'origin/master'),
+ array('doctrine-common', 'http://github.com/doctrine/common', 'origin/master'),
+ array('doctrine-dbal', 'http://github.com/doctrine/dbal', 'origin/master'),
+ array('doctrine-orm', 'http://github.com/doctrine/doctrine2', 'origin/master'),
+ array('doctrine-mongodb', 'http://github.com/doctrine/mongodb', 'origin/master'),
+ array('doctrine-mongodb-odm', 'http://github.com/doctrine/mongodb-odm', 'origin/master'),
+ array('propel', 'http://github.com/propelorm/Propel', 'origin/master'),
+ array('solarium', 'http://github.com/basdenooijer/solarium', 'origin/master'),
+);
+
+foreach ($deps as $dep) {
+ if (3 === count($dep)) {
+ list($name, $url, $rev) = $dep;
+ $target = null;
+ } else {
+ list($name, $url, $rev, $target) = $dep;
+ }
+
+ if (null === $rev) {
+ $rev = 'origin/master';
+ }
+
+ if (null !== $target) {
+ $installDir = $vendorDir.'/'.$target;
+ } else {
+ $installDir = $vendorDir.'/'.$name;
+ }
+
+ $install = false;
+ if (!is_dir($installDir)) {
+ $install = true;
+ echo "> Installing $name\n";
+
+ system(sprintf('git clone %s %s', escapeshellarg($url), escapeshellarg($installDir)));
+ }
+
+ if (!$install) {
+ echo "> Updating $name\n";
+ }
+
+ system(sprintf('cd %s && git fetch origin && git reset --hard %s', escapeshellarg($installDir), escapeshellarg($rev)));
+}

0 comments on commit 13722fe

Please sign in to comment.