#!/usr/bin/env php setDownloader('git', new Downloader\GitDownloader()); $installer->setDownloader('pear', new Downloader\PearDownloader()); $installer->setDownloader('zip', new Downloader\ZipDownloader()); // initialize composer $composer = new Composer(); $composer->setInstaller('library', $installer); $composer->setRepository('Platform', new Repository\PlatformRepository()); $composer->setRepository('Packagist', new Repository\ComposerRepository('http://packagist.org')); // initialize package $loader = new Package\Loader\Json(); $package = $loader->load('composer.json'); // initialize lock $packageLock = new Package\PackageLock('composer.lock'); // run the command application $application = new ComposerApplication($composer, $package, $packageLock); $application->run();