write("Validating plugins...");
foreach ($this->container['plugins.explorer'] as $directory) {
$manifests[] = $manifest = $this->container['plugins.plugins-validator']->validatePlugin($directory);
}
$output->writeln(" OK");
return $manifests;
}
protected function doExecute(InputInterface $input, OutputInterface $output)
{
if (basename($_SERVER['PHP_SELF']) === 'console') {
$output->writeln("");
$output->writeln(sprintf(' /!\ Warning, this command is deprecated and will be removed as of Phraseanet 3.9, please use bin/setup %s instead /!\ ', $this->getName()));
$output->writeln("");
}
return $this->doExecutePluginAction($input, $output);
}
abstract protected function doExecutePluginAction(InputInterface $input, OutputInterface $output);
protected function updateConfigFiles(InputInterface $input, OutputInterface $output)
{
$manifests = $this->validatePlugins($input, $output);
$output->write("Updating config files...");
$this->container['plugins.autoloader-generator']->write($manifests);
$output->writeln(" OK");
$output->write('Building LESS assets');
$this->container['phraseanet.less-builder']->build($this->container['phraseanet.less-mapping.customizable'], $output);
$output->writeln(" OK");
}
}