2011-07-14 17:41:28 +02:00
|
|
|
#!/usr/bin/env php
|
|
|
|
<?php
|
|
|
|
/*
|
2011-07-18 22:43:12 +02:00
|
|
|
* This file is part of the BeSimpleSoapBundle.
|
2011-07-14 17:41:28 +02:00
|
|
|
*
|
2011-07-17 10:46:54 +02:00
|
|
|
* (c) Christian Kerl <christian-kerl@web.de>
|
2011-07-14 17:41:28 +02:00
|
|
|
*
|
2011-07-17 10:46:54 +02:00
|
|
|
* This source file is subject to the MIT license that is bundled
|
|
|
|
* with this source code in the file LICENSE.
|
2011-07-14 17:41:28 +02:00
|
|
|
*/
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
2011-07-18 22:43:12 +02:00
|
|
|
CAUTION: This file installs the dependencies needed to run the BeSimpleSoapBundle test suite.
|
2011-07-14 17:41:28 +02:00
|
|
|
|
2011-07-17 10:46:54 +02:00
|
|
|
https://github.com/BeSimple/BeSimpleSoapBundle
|
2011-07-14 17:41:28 +02:00
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
if (!is_dir($vendorDir = dirname(__FILE__).'/vendor')) {
|
|
|
|
mkdir($vendorDir, 0777, true);
|
|
|
|
}
|
|
|
|
|
|
|
|
$deps = array(
|
|
|
|
array('symfony', 'http://github.com/symfony/symfony.git', 'origin/HEAD'),
|
|
|
|
array('zend', 'http://github.com/zendframework/zf2.git', 'origin/HEAD'),
|
|
|
|
);
|
|
|
|
|
|
|
|
foreach ($deps as $dep) {
|
|
|
|
list($name, $url, $rev) = $dep;
|
|
|
|
|
|
|
|
echo "> Installing/Updating $name\n";
|
|
|
|
|
|
|
|
$installDir = $vendorDir.'/'.$name;
|
|
|
|
if (!is_dir($installDir)) {
|
|
|
|
system(sprintf('git clone %s %s', escapeshellarg($url), escapeshellarg($installDir)));
|
|
|
|
}
|
|
|
|
|
|
|
|
system(sprintf('cd %s && git fetch origin && git reset --hard %s', escapeshellarg($installDir), escapeshellarg($rev)));
|
|
|
|
}
|