git submodule add -f git://github.com/tumf/PearBundle.git vendor/bundles/Tumf/PearBundle
git submodule init
git submodule update
// app/AppKernel.php
$bundles = array(
new Tumf\PearBundle\PearBundle(),
);
// app/autoload.php
$loader->registerNamespaces(array(
// ...
'Tumf\\PearBundle' => __DIR__.'/../vendor/bundles',
// ...
));
set_include_path(get_include_path() . PATH_SEPARATOR.__DIR__.'/../vendor/pear/php');
- pear:exec [.... ]
- pear:init
setup pear
./app/console pear:init
discover pear channnel
./app/console pear channel-discover openpear.org
install Acme_Morningmusume from openpear
./app/console pear install openpear/Acme_Morningmusume
add autoload.php
$loader->registerPrefixes(array(
//...
'Acme_' => __DIR__.'/../vendor/pear/php',
));
use
$mm = new \Acme_MorningMusume;
var_dump($mm->members);
pear:
command: /path/to/pear