public function activate(Composer $composer, IOInterface $io)
{
$this->io = $io;
$this->composer = $composer;
$this->filesystem = new Filesystem();
$this->config = new ProjectConfig($composer->getPackage()->getExtra());
$this->installer = new Installer($io, $composer);
$this->initDeployManager($composer, $io);
$this->installer->setDeployManager($this->deployManager);
$this->installer->setConfig($this->config);
if ($this->io->isDebug()) {
$this->io->write('activate magento plugin');
}
$composer->getInstallationManager()->addInstaller($this->installer);
}