mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-25 11:38:44 +02:00
Merge remote-tracking branch 'origin/support/3.2' into develop
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
|
||||
namespace Symfony\Bundle\FrameworkBundle\Command;
|
||||
|
||||
use Psr\Container\ContainerInterface;
|
||||
use Symfony\Component\Config\Definition\ConfigurationInterface;
|
||||
use Symfony\Component\Config\Definition\Processor;
|
||||
use Symfony\Component\Console\Attribute\AsCommand;
|
||||
@@ -39,9 +40,15 @@ use Symfony\Component\Yaml\Yaml;
|
||||
#[AsCommand(name: 'debug:config', description: 'Dump the current configuration for an extension')]
|
||||
class ConfigDebugCommand extends AbstractConfigCommand
|
||||
{
|
||||
public function __construct(
|
||||
private ?ContainerInterface $envVarProcessors = null,
|
||||
) {
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
protected function configure(): void
|
||||
{
|
||||
$commentedHelpFormats = array_map(fn ($format) => \sprintf('<comment>%s</comment>', $format), $this->getAvailableFormatOptions());
|
||||
$commentedHelpFormats = array_map(static fn ($format) => \sprintf('<comment>%s</comment>', $format), $this->getAvailableFormatOptions());
|
||||
$helpFormats = implode('", "', $commentedHelpFormats);
|
||||
|
||||
$this
|
||||
@@ -146,6 +153,9 @@ EOF
|
||||
|
||||
$method = new \ReflectionMethod($kernel, 'buildContainer');
|
||||
$container = $method->invoke($kernel);
|
||||
if ($this->envVarProcessors) {
|
||||
$container->set('container.env_var_processors_locator', $this->envVarProcessors);
|
||||
}
|
||||
$container->getCompiler()->compile($container);
|
||||
|
||||
return $container;
|
||||
|
||||
Reference in New Issue
Block a user