forked from BabDev/Pagerfanta
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
Showing
14 changed files
with
87 additions
and
56 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
phpunit.xml | ||
/tests/autoload.php | ||
/vendor/ |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -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(); |
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,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
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 |
---|---|---|
@@ -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))); | ||
} |