src/Mouf/Composer/ComposerService.php
public function getLocalPackages() {
		$composer = $this->getComposer();
		$dispatcher = new EventDispatcher($composer, $this->io);
		$autoloadGenerator = new \Composer\Autoload\AutoloadGenerator($dispatcher);
		
		if ($this->selfEdit) {
			chdir(__DIR__."/../../..");
			\putenv('COMPOSER=composer-mouf.json');
		} else {
			chdir(__DIR__."/../../../../../..");
		}
		//TODO: this call is strange because it will return the same isntance as above.
		$composer = $this->getComposer();
				
		$localRepos = new CompositeRepository(array($composer->getRepositoryManager()->getLocalRepository()));
		$package = $composer->getPackage();
		$packagesList = $localRepos->getPackages();
		$packagesList[] = $package;
		
		return $packagesList;
	}
public function getLocalPackages() {
		$composer = $this->getComposer();
		$dispatcher = new EventDispatcher($composer, $this->io);
		$autoloadGenerator = new \Composer\Autoload\AutoloadGenerator($dispatcher);
		
		if ($this->selfEdit) {
			chdir(__DIR__."/../../..");
			\putenv('COMPOSER=composer-mouf.json');
		} else {
			chdir(__DIR__."/../../../../../..");
		}
		//TODO: this call is strange because it will return the same isntance as above.
		$composer = $this->getComposer();
				
		$localRepos = new CompositeRepository(array($composer->getRepositoryManager()->getLocalRepository()));
		$package = $composer->getPackage();
		$packagesList = $localRepos->getPackages();
		$packagesList[] = $package;
		
		return $packagesList;
	}
public function getLocalPackages ( ) { $ composer = $ this -> getComposer ( ) ; $ dispatcher = new EventDispatcher ( $ composer , $ this -> io ) ; $ autoloadGenerator = new \ Composer \ Autoload \ AutoloadGenerator ( $ dispatcher ) ; if ( $ this -> selfEdit ) { chdir ( __DIR__ . "/../../.." ) ; \ putenv ( 'COMPOSER=composer-mouf.json' ) ; } else { chdir ( __DIR__ . "/../../../../../.." ) ; } //TODO: this call is strange because it will return the same isntance as above. $ composer = $ this -> getComposer ( ) ; $ localRepos = new CompositeRepository ( array ( $ composer -> getRepositoryManager ( ) -> getLocalRepository ( ) ) ) ; $ package = $ composer -> getPackage ( ) ; $ packagesList = $ localRepos -> getPackages ( ) ; $ packagesList [ ] = $ package ; return $ packagesList ; }
Returns an array of Composer packages currently installed.

@return PackageInterface[]
Returns an array of Composer packages currently installed .